Tried this on a Lenovo notebook and it will reinstall the Lenovo bloatware anyways. I think this restore the initial windows image state, but the image that came in the notebook is customized by Lenovo.
Yes, the 'refresh Windows' feature actually reinstalls from the image OEM provided, which contains all the bloatware. You need to create a fresh install media from Microsoft (their media creation tool) and reinstall from DVD and delete the OEM recovery partitions to finally be rid of them.
I believe it's even more sinister than that. I recall reading about a feature of Windows 10 where it will automatically install OEM bloatware from separate storage on the board, even if you install from a generic Window disk/USB. I'm trying to find a source.
Edit: I cannot find a source, so take this with a grain of salt, however I do clearly remember reading it.
I believe the one you're referring to is the "Windows Platform Binary Table (WPBT)" feature, which has a slot in UEFI where an exe can be put, which is run by Windows during an install.
It actually runs on every boot, even worse. This is how overbroad nanny software like Computrace works, you can remove it but Windows will just reinstall it at boot.