Is it possible, to integrate an external motor to the Raspberry Pi with Octoprint? You can connect the motor to the pins of the Raspberry Pi. Is it possible to control the motor in the Octoprint program by using Python? Or are there any other possibilities, to control the external motor?
Yeah that's possible.
Here are two plugins which you can use to control servos
If they don't meet your expectations, you can use them as a template to develop your own plugin
Most motors (not small servos) require far more current than the GPIO (logic) pins on the Pi can provide, you usually need some kind of controller as well.