Full disclaimer upfront: Do not know how.
That said if I had to do that there would be two requirements:
1) I would need to build the necessary circuitry to recharge the working Li-ion battery from a power source be it a local wall outlet or maybe USB.
2) I would need to build the necessary circuitry to recharge the phone from the Li-ion battery.
In both cases would need to map and match the required voltages, amps, etc. with the necessary circuitry to indicate status, prevent overcharging etc..
It should be fairly easy to find schematics on the internet for such circuits. Especially if you are an electronics hobbyist or EE type and can read the circuits. All you would be doing thereafter is applying the circuitry for a...