Data-driven approximation of the Koopman generator: Model reduction, system identification, and control