The odds are lower that they'll leave than someone with less experience needing more time to become senior. There is no substitute for experience.
EDIT: To expound on this, as a manager, I will look out for the company, but also for you. If you have limited experience and want to climb the ladder, I will help find you a path internally and if one is unavailable (happens all the time), I will introduce you to opportunities outside the org to get you into higher roles and pay grades. Same deal if you're a senior person with "too much skill" for the role: tell me your goals, and I will help you get there. No one sticks around forever, and its unrealistic to ask people to do so.
This is, in my opinion, what a good manager is. Not someone who can code well, not someone who is a technical wizard, but someone who manages away problems outside of the team while helping individual contributors maximize their potential.
You're under the impression (it seems, correct me if I'm wrong) that labor is entirely fungible in an org and you can just shuffle people around to match skills to tasks; rarely is that the case, whether you're a company of 80 or 8000.
Managing people is super hard, and technical skill overlap with management skills is almost non-existent.
Of course, this would be incredibly illegal and unethical.
I didn't mean that entirely seriously but it does seem that the labor market still hasn't recovered from the recession when it very suddenly became a buyers market. In theory, it could have by now but it feels as if the job market is still being kept at an artificial scarcity, maybe because companies are still afraid to spend on people, or because they're trying to eke out every last cent of profit regardless of future.
I've only been at one job so far, but my opinion was that I would suffer literally zero short-term effects for getting fired/laid off. I probably would just end up at a better job since I've got a bigger network and time to spend grinding out interviews if that happened.
So in the end my employers would act the way you described, but I would be confused about how to respond to them as they had zero objective leverage over me. As a result I could pretty much just work a regular 40 hours and my boss could just blow smoke out his ears if he didn't like it.
As an aside I actually don't have an issue working extra hours sometimes, but 100% of the time I'd been asked to, I thought it management was responsible via poor planning or making shitty technical choices. I'm fine helping out to cover someone else's bad work, but people would just become more rude/demanding. So I would just stop since I was only working extra out of kindness in the first place.
If you insist on paying more experienced people the same as less experienced people, then all you're going to hire are less experienced people. That has nothing to do with either age discrimination or over-qualification, though. It has to do with you, the employer, being penny wise and pound foolish.