I dont think it can be done mainly because the modems/routers most people use are the ones that they get from their providers and those are locked (can't install apps) and very weak in hardware so even if you could install a proxy server it would cause issues (slow response and processing). If the modem can use OpenWrt OS, then you can install a proxy, otherwise probably not. This is as far as the hardware goes.
On the practical side and since you are not telling us the reason for doing this, you need to know that since most people use asymmetrical lines (the download is much greater than the upload) your connection speed will be way slower than you might think. If for example, they have 50/5 since they will "download" for you and then transmit it to your IP, you will be bound by their upload speed so you will surf the internet or download with 5 Mbits at best. If they happen to use their interest too for streaming, browsing, etc, your speed will be even lower, or you both will have lag issues since both of you use the very limited upload channel. And the more people that use the same modem, the worse it will be for all.
If you only do this to mask yourself for being "naughty", it won't be much of a protection since this will be easily discoverable. If you do this to use multiple modems at the same time... it won't work, you can only use one at a time/task and even then, the delay will be horrible. The only thing I can think of is to use several as a proxy chain but then your ping will skyrocket especially as those people use their internet too.
Most of the above apply also with using any mini PC as the upload channel is fixed.
Hope it helped.