First of all - welcome to BC !
What do you mean when you say your laptop is charging while it is supposed to be asleep ? Do you mean that the power light is still on ? If you do, this is, as far as I know, entirely normal - it merely shows that the external supply is connected and live. Certainly this is the case with the four laptops I am responsible for and they are of four different makes and ages ranging from two years to ten years old.
I have seen advice from a battery supplier suggesting that the best way to extend battery life is to charge the battery on the computer to between 95 and 100%, then run it on battery power to about 10 - 15% capacity, then re-charge.
If you are concerned about the safety aspect of leaving your computer plugged in while you are away for perhaps an extended period, then don't put it to sleep but turn it off and then disconnect the power supply.