Ha, just realised im answering you in 2 threads..
Ebikes are very modular, there is the bike, the motor, the battery and the control system thats it.
there are 2 options when it comes to motors, Hub/wheel drives, or mid drives, hub motors are literally fitted into replacement wheels, mid...