If you still have one of these and have previously been unsuccessful with unlocking due to the phone being 'active on another account' (whether or not that's actually true), I suggest you try again on AT&T's unlock portal: https://www.att.com/deviceunlock
I kept around such a phone: an iPhone 5s with a lot of screen white spots. I had a hunch that it would get kicked out of AT&T's system after their 3G network shutdown. It didn't work when I tried in April but I tried again last weekend and it unlocked! It connects to the T-Mobile network when I insert an active SIM.
T-Mobile says it's shutting down it's native (not Sprint's) 3G network as of July 1, 2022.
The 5s might continue to work on T-Mobile on its 2G network for voice while retaining access to 4G LTE data. I know that my 4s works on T-Mobile's 2G network when I turn off 3G.
It might indeed and T-Mobile has not yet said when it will shut down its 2G network. Mostly, it's being kept alive for now for IoT devices.
Not sure that T-Mobile 2G will work on MVNOs. I'm suspecting that recent activations on T-Mobile are being executed without 2G/3G access whatsoever.
I pulled the my FreedomPop free GSMT SIM from my kid's smartwatch into an iPhone 4s. It doesn't work.
My data only SIM from main T-Mobile is working, but that SIM was activated more than 2 years ago.
After the July 4 weekend, I'm going to activate a Mint Mobile trial SIM and a Ting $.99 SIM I got from Target to see if they will work on the 4s.