Just as an anecdote. I was in a doctoral program in engineering, and I mastered out into a 90k/yr job (this was in the early 2000s) writing cplex code to optimize supply chains. A buddy in the PhD program was doing nearly identical work for a 15k/yr stipend.
Students by contrast need professors for training and advice. Whether they receive these from their advisor depends on the lab. In bigger labs junior students learn more from senior students and post-docs than professors.