To control the speed you have to use PWM on the control pins (IN1A, IN2A for channel1, IN1B, IN2B for channel2). It uses the same pins when in PHASE mode, but the names differ.
Read the datasheet and look at chapter 8 for the difference between the two modes. In the IN mode it shorts the motor to break it, in PHASE mode it does not.
When using IN mode the control needs to vary between low,low and low,high to go backwards and high,low and low,low to go forward. This means to control the speed you have to enable PWM on only one of the two lines, depending on the direction you want to go in. Making both lines high will apply break to the motor, which will give it erratic behavior.