If you are wanting to power a microprocessor, you need to more than likely reduce the power down the the required voltage as needed by the microprocessor. Most will either be 3.3V or 5V. Look up voltage regulators and how to use them. Switching regulators are more difficult to wire up and usually require a PCB unless you get a pre-made switching regulator like this one R-78E5.0-0.5 which is a 5V switching regulator. You will need filter caps across the output and ground to prevent a ripple in the voltage. You can also use LDO (Low drop out) regulators which would be easier to wire up.
To control the motor with your batteries and the microprocessor, you will need to use an NPN transistor to control the low side (ground) connection to the motor. One lead of the motor will be connected directly to the battery positive, and the negative of the motor will be connected to the collector of the NPN transistor which will be controlled by the microprocessor. You will need to put a current limiting resistor on the base of the transistor and the value will depend on the voltage and current source ability of the processor. The Emitter of the transistor will be tied directly to ground (Negative side of the battery).
When switching a motor on and off, it will create what is called flyback voltage which needs to be controlled via a diode across the motor's leads. This will prevent unwanted voltage spikes getting to your processor and causing unwanted effects. Hope that helps!