> Electric trains have banks of resistors used to dump the unwanted kinetic energy when it's not possible to return it to the power supply
On AC-electrified railways (especially those with their own independent power supply network like Germany/Austria/Switzerland), resistors are actually rather uncommon on stock capable of regenerative braking, because the OHLE not being able to accept regenerated power is a relatively rare occurrence.
Though of course in that case the conventional friction brakes are of course fully rated to bring the train to halt, only with a bit more wear and tear.
DC-electrified railways are a different matter – transmission losses are higher, power supply sections are smaller and substations often not capable of returning any surplus power back into higher network layers of the power supply systems, so the OHLE/third rail not being able to accept the power generated by regenerative braking happens much more frequently and so trains continue carrying braking resistors as a fallback system.