These are people who have consistently been able to recruit, hire, and retain a lot of very high-performing people... the kind of people who can choose where to work. And as leaders, they have been liked and admired by the vast majority of their staff, and millions of customers and fans.
Furthermore these are people for whom being popular is incredibly important, and they have spent a tremendous amount of energy on it. Steve Jobs was famous for how much personal time he put into marketing, press relations, and his own personal brand. Same with Elon Musk, which is why he is so active on Twitter, for example.
Were they nice to every single person they ever met? No, and sure, that's good advice: don't feel like you need to suck up to everyone. But IMO that's very different from the idea that one should strive to be unlikeable.
PLENTY of people are unlikeable already, with not much to show for it. What made Steve Jobs and Elon Musk remarkable was that they were right so often, about complicated and important things. So: maybe we should instead strive to be more right about things that matter.