Practise I guess, or just an ability to separate the two things mentally, rather like playing a syncopated bass line and singing at the same time. Although not in the same league, I was called on to sing Bowie’s China Girl. Couldn’t do it at first, but with lots and lots of practise behind closed doors, accompanied with lots of errors, I finally nailed it. Drummers and keyboard players have this separation as an essential part of what they do and then many sing as well. Flash buggers 😂