Yes they need electricity to pump the air otherwise how would they pump it? Magic?
I am not sure on how they actually work but I know that a diaphraghm is involved. If this breaks then the pump won't work. Beyond that the mechanics of air pumps is unknown to me.
Battery operated pumps are usually an emergency option and not practical for long term use unless you like buying lots and lots of batteries.