How to unlock an iPhone 5s t-mobile?

I recently found an iPhone 5s at school I tried looking who's it was to return it but I never found the owner so I came home and put it into recovery mode and updated and restored it but now i don't know how to unlock it to use it on my carrier I tried searching but it sends me to the t-mobile support page I want to factory unlock it not caring about the price but if it's really expensive then I might as well just buy a factory unlocked iPhone 5s.

It all depends on the original carrier. Find the IMEI number of the phone, check its carrier, find if it is possible to (factory) unlock it and check the price of that. See the link for checking the IMEI.

You can easily get that phone factory unlocked but that won't unblock the blacklisted IMEI as it's reported lost / stolen. So you've to get it unblocked and unlocked to use it on your carrier. It won't cost you a fortune for that. If you need to get the phone unblocked / factory unlocked, mail me for references.