How do electric generators produce a current?
By controlling random motion of electrons in metal to specific direction by magnetic fields.
Since electrons are deflected by magnetic field the free electrons in metal wounded as armature gets deflected by alternating magnetic field provided by magnets. Direction of current is given by fleming's right hand rule. It is opposite to direction of movement of electron.