It turns out, somewhat counter-intuitively, those dimples significantly decrease the drag on the golf ball as it flies through the air compared to a smooth ball. Not only that, but they also increase the lift somewhat. These two things combined can make the golf ball go as much as three times farther than the same ball without dimples.
The dimples on golf balls accomplish both of these things by creating turbulence in the layer of air around the golf ball called the boundary layer. In simple terms, the dimples more or less scoop the air and direct it inwards towards the back of the golf ball. This effectively increases the net air pressure in the back of the ball which reduces the drag by reducing the pressure pulling back at the ball from behind. This can reduce drag by as much as 50% over a smooth ball.