grad school is definitely a prestige move. not a 'get rich move', but def a prestige move. prestige is not just money.
for med or law school, there are very clear hierarchies about who's better than who and next steps in your career. you get money AND intellectual status.
but for other sciences and humanities, it's a flex about pursuing abstract "truth" or "knowledge" of "beauty" or whatever and not caring about financial success. it is very monastic in that people make a show of forgoing traditional measures of status in service of their "calling".
... but as high-minded as these people are there is still a very clear hierarchy that lets you compare rank/compare yourself against your other recent grads so you can talk about who's doing well and who isn't even though none of them have money.
BUT grad school for CS and engineering is different because there's so much money and employability at the end of the rainbow. these aren't really a calling in the same way, and are closer to MBA degree becayse it's just a thing you do to get more money later. A comp sci PhD with a job in industry is lauded, but those folks don't understand the deep sense of failure that a non-CS PhD feels when they have to 'resort to' an industry job in the private sector