it is actually more complicated than that. first of all there are two components of electrical output: active (MW) and reactive (MVAr). Active power output is equal to active power input from the turbine, proportional to the gas-regulated by governor. reactive component has got something to do with the excitation and regulated by exciter. Governor controls the turbine, exciter controls the generator.
suppose generator is connected to a grid which is way larger than the capacity of the generator, i.e. your generator is not a significant factor compared to overall grid.
say your generator is producing the active preset power P(MW) at the grid frequeny. governor is controlling the turbine to produce power P at a speed that corresponds to grid frequency. If somehow the grid frequency increases, your frequency will increase too (because you are synchornized with the grid), proportionally you will start producing more power. Governor settings will have to be changed to bring the increased power output to preset P value. Similar thing for the frequency decrease.
governor is relatively easier to understand, because it is dealing with real power. However, there is an exciter system too, pretty much doing the same thing, by under or over exciting the windings, controlling the reactive power to the system, thus the voltage.
In summary you have the power P-made of components V and I. You control P by governor, and V by exciter. Since P is proportional to V and I, by controlling P and V, you control everything.
Hope this helps