Each CNC Shield can control 4 motors. Since I needed 5 motors, I put 3 motors on one CNC Shield and 2 on the other CNC Shield.
You only have to connect the Step and Dir signals from the controller to the corresponding inputs. Also you have to connect the 5V and GND from the controller. At last you need the 12V for the supply of the motors. Remember to set the jumper for the enable signal.(Yellow bounding)
I hope this helps you. Let me know if you have any questions.