What makes you think this - and what makes you think that so many folks have so much agency in their life? A lot of folks don't, and if you have depression, you generally have even less of it because you wind up with an inability to see options you do have... if any.
It isn't like everyone can escape poverty or a bad spouse (it takes money to divorce someone or even leave if you need to get your own place). It isn't like anyone can magically make a disease diagnosis go away nor does changing jobs always fix things, especially if the reason you stay is because you desperately need the health insurance or because no where else pays as much in your area (and moving costs money).
We don't make sure folks have tools to improve their life.
Additionally, this really just blames the victim and I really hope you don't say this to folks actually suffering.