Uh, I mean, it's a source of drag. It lets the air stick to the surface and tumble behind the ball in wild whipping whirlpools. The energy in the boundary layer is lost energy. The less drag, the farther the ball will be driven. Here's where the dimples do their job.
Dimples make the molecules in the layer tumble.
They start roiling against one another. The molecules in the layer are no longer just sliding across the surface gently jostling. Now, they're rolling and bouncing and bumping each other along. When the molecules are in a turbulent boundary layer, they're moving closer to the free-stream speed. There is less of a difference between the speed of the tumbling molecules and the speed of the ball.