Can there really still be electricity inside the unit even after the mains plug has been disconnected?

Yes! Flash units use capacitors to collect power, store it, and release it “in a flash” as a light pulse via the flash tube! So, if just the mains plug is disconnected or the unit is switched off, there may still be a charge in the capacitors. Depending on the type of unit, the charge is either automatically released via flash when turning off the unit, discharged via resistors, or depletes with time on its own. But even after manual flash release, the condensers still store some remaining charge. So, please make sure that the capacitor charge has been completely discharged before doing repairs.