Sometimes with cheaper models the phone company hasn't bothered to lock the phone to its service. If it has, it's possible to get it unlocked by the sort of independent shops which sell phone accessories.
However, though these shops probably charge less $10, these days it is quite possible to find a new phone for about $20. Given that locating a replacement battery for an older phone can be difficult and cost more than $20, your act of kindness may not be very cost effective.