Keys are encrypted with your password and then synched to the server. When you login on another device encrypted keys are downloaded and decrypted locally using password.
Got it, I was not aware of the key encrypted with password part
Thanks for the help!