Whenever I switch keyboard layout in macOS, it also switches it in Windows, and vise versa. How can I turn it off?
In order to disable keyboard layout synchronization, you need to manually modify config.pvs file.
Shut down your virtual machine (Actions > Shut down). If it is in a suspended state, resume it and then shut down.
Right-click Parallels Desktop icon > Control Center.
Right-click the name of your virtual machine > Show in Finder.
Right-click the .pvm file > Show Package Contents.
Right-click the config.pvs file > Open With > TextEdit.app.
In TextEdit, press Cmd+F shortcut and locate the following part:
<KeyboardLayoutSync dyn_lists=""> <Enabled>1</Enabled>
And change 1 to 0. It should look like this:
<KeyboardLayoutSync dyn_lists=""> <Enabled>0</Enabled>
Save the changes in config.pvs file and close it. Run the virtual machine. Now, keyboard layouts are not synchronized and will not be changed automatically.