Hey there, welcome to the biking world lol.
Anyway, I'm not very sure of the exact steps but here are some pointers you might find useful.
Firstly, if the bike is fully paid and owned by your friend, you will have to pay the amount both of you agreed on and just have to transfer the ownership and the bike is yours!
But wait, you'll have to get your own insurance before you can ride the bike. So find any one of your preferred insurance company to get a minimum of a third party insurance to start riding!
If the bike is still under installment, you can either pay full to own the bike or you can become a sub-rider of the bike and continue the installment. However, I think both of you must have a certain trust in each other to do this because all the fines will still be sent over to the main rider if even if it's the sub-rider who incurred the fine.
For first hand bike I'm not too sure but it's probably more or less the same, just that instead of your friend you're buying from, it's the bike shop. Cos' I don't intend on buying first hand now anyway, it's not gonna be worthed it for 2b bikes.
Road tax has to be renewed every 6 months or 1 year when it's expired.
Cost of insurance depends on your age, bike model and many different criteria. You can call them up to get a quote.
Hope these helps! Good luck!