That's horrible but not unheard off.
My company was very open about mental health, we had open talks between workers, and all was good. But at some point, I think an undesired critical mass of people with mental disorders (from autism and adhd, to burn out and depression) was reached and suddenly talking about it was no longer OK. It was "bringing the mood down".
Managers started cutting down on opening up too much to colleagues. Disciplinary action was applied to people who didn't comply, disguised as "performance improvement plans" to "improve their communication". Complaining about this publicly led to more PIPs, and eventually firings. 3 of the most vocal people about mental health were fired because "they didn't fit the company culture". Now the company offers free therapy which you are invited to use in private.
So yeah. Companies only care about mental health to a point.