im not sure of the process, but the r pronunciation of spanish speakers are learned near birth when the language is introduced early in their lives, similar to any other language. This is why some people have accents when speaking a non-native language