Do you think it's possible to pay off student debt during a PhD?
Possible, but very difficult.
A typical annual stipend for a US PhD student in the $20k-$30k range. If you allocate $10k of that stipend each year to paying off debt, the leftover income will put you near the federal threshold for poverty-level income for a single individual (~$13k). If you take into account that the cost of living is usually quite a bit higher in large cities, you would usually have to live a very meager existence for several years in order to pay off $40k worth of debt on only a PhD stipend. It's not outright impossible, but you'd need to be extremely motivated, diligent, and willing to live in poverty (or at least poverty-adjacent) to accomplish such a thing. Of course, this becomes easier if you enjoy a larger-than-average stipend. Pooling expenses in a shared living situation can also make things easier, as the poverty threshold for a larger household is not a simple multiple of the individual's threshold.
I would expect this level of saving/debt payoff to be very atypical among PhD students who live off their stipend alone.