Iphone charging and battery problems?

I recently got a second-hand iPhone from a friend, which she has been using for some years. The big problem is that it charging extremely slowly and the battery depletes with a rate of like one percent per minute while using it. I have 3 apple chargers, also in use for other devices, and they all work, so that can't be the problem.

Is it a problem with the battery? And if, can I replace that battery?

Fix iPhone Battery Charging Problems

My iPhone started exhibiting problems with battery. The battery would not charge at times, it drained fast and the phone ran hot. These are the steps I took to fix the problem.

Backup and sync your phone. Connecting your phones to iTunes and doing a sync will also backup your phone.
Reset your settings. Settings -> General -> Reset -> Reset All Settings.
Hard Reset your iPhone. Press and hold the home button and the power button together until the silver apple logo is shown on screen [First the "Slide to Power Off" message will appear and then the screen will go blank and then the apple logo will appear]. Once the apple logo appears you can release the buttons.
Disable Push for your accounts. To disable Push you need to go to Settings -> Mail, Contacts, Calendars -> Fetch New Data. Turn Push off and set the fetch interval to whatever you desire.

wkr p