Sure, but its skills easy enough that teenagers self-teaching is considered common. Its much easier than most "professional" jobs, like doctor.
When we hear stories like those the reaction tends to be "damn that must be a really smart kid".
I don't see any reason why equally smart kids couldn't teach themselves medicine, just as many professional sports players, artists, musicians, mathematicians, etc, tend to start playing from a very young age.
Some external differentiators seem to be "access to learning materials" and "regulation of access to a profession". As an example for that second point: there is absolutely a level of professional and personal maturity I expect from a doctor, that I don't expect the tech industry to screen for. Though I'm also not suggesting the current student -> doctor pipeline is ideal either.
Self-teaching is also possible and a common route for auto mechanics, who make about as much as tech workers. They know how to do things that both doctors and SWEs are willing to pay for. Can your doctor rebuild his own car engine?
When I explain my job to people, I usually compare it to being an auto mechanic, not a doctor. That is what most software engineering boils down to. And in fact, our paths are converging with mechanics.
High pay means that the person creates a lot of value and that there's low supply relative to demand. High pay is offered because employers want to attract workers. If they're paying well, they're probably going to try other things to attract workers as well, such as offering better working conditions.
Low pay means you don't have to try too hard to get workers. That means you don't have to be nice to them.
Or that it requires a set of skills that not everybody has, or that there is a competitive market where employees can select jobs based on pay. Those are two other reasons.
Indeed, I have to question the premise that high pay and shitty jobs go together. I can think of plenty of shitty, low-paid jobs.