Tenir isn't the right translation for hold in this case. Unfortunately, I can't think of a similar word in French to say to hold a charge for a battery. The only thing that comes to mind is: Les batteries ne restent pas chargées. (the batteries can't stay charged)
Also, pile = the small batteries that one buys in a supermarket for a cd player (like Duracel batteries). For a laptop, a cellphone, a car, etc. (any equipment that comes with a special battery), use the word batterie.