What is the working principle of water heater, iron box, and electric kettle ? In other words how is heat generated in these device ?
The electric current flows through a conductor which heats up and heat energy is produced.
An electric generator is a device which works on the principle of electromagnetic induction.