Labor mobility is unequivocally not a market failure.
The 3 types of market failures are:
- Anti-competitive markets
- Suboptimal initial resource allocation
Gaining vocational skills is none of these 3 things. When a person gains skills, that gives them value because they can be more productive and therefore can command a higher pay. This is clearly not an externality, the skill learner has full incentives to gain skills that are worth gaining. If a company trains their employees, there is some potential friction there, but again, these are consensual actions where companies train their employees expecting that they'll be more productive because of it. This is also not an externality.
If training was actually being wasted by employees leaving right after they're trained, companies would simply find another way to operate, for example by requiring employees to pay for their training in some way (or forgo full wages until their training is complete). There is no reason to expect that people are actually learning lower than optimal levels of skills for any reason of market failure.
More likely, the reason is actually one of a lack of knowledge. People have limited knowledge and a limited ability to analyze their opportunities. People will inevitably make mistakes and do things that are suboptimal. However, this is not a market failure. The cost of acquiring more knowledge and more carefully analyzing opportunities is costly, and many people rationally choose not to bear those costs when they believe they aren't worth it.
The fact that some external person can say people should get more training is immaterial. Market failure is not simply suboptimal behavior, it is something much more than that.