Some are simple returns, machines not returned for any hardware problem, cleaned up, factory software reinstalled, and put in new packaging. That's probably the best.
My father-in-law recently bought a refurbished desktop computer on Amazon but it didn't come with the built in wifi promised. He settled on a partial refund, more than enough to buy a usb wifi stick.
The last new computer I bought was a Raspberry Pi for $35. Otherwise I generally find my computers in the recycling bins or left curbside with broken microwave ovens and stuff. If a machine is better than my current desktop I'll max out its memory, install Debian (Linux), and that becomes my new desktop machine.
The last "new" computer I bought was a shopworn 386, sometime in the 'nineties. I later upgraded it using an Evergreen 486 chip and installed Windows 95 Lite. Thanks to modern software bloat that machine seemed as fast as any modern Windows 10 machine. I used the Opera browser, which was a much better browser than Netscape or Internet Explorer. I bought sound editing software suite too that seemed pretty miraculous for its time. It was great for removing 60 Hz power line hum from old tape recordings. (Doing the same with analog filters wasn't as easy and the results were not as good.)
I don't play any cutting edge video games or edit videos. The most computationally intensive thing I do is frequency separations on still photographs and even those are quick enough that it's not worth leaving my chair.