Good Buck Converter driver IC for Arduino

Your charger also needs to consider balance between the cells , constant current then constant voltage phases , then knowing when to stop charging .
Measuring battery temperature and also separate protection for under and over voltage .

Not too easy , study the battery chemistry and how to charge and maintain the batteries first !!