Many years ago, Golf balls used to be smooth round balls, but someone realized that used, scratched, dented balls go farther than a new & shiny one.
The reason behind that was, on a smooth ball, the air drift separates quickly from the ball and it doesn’t carry it too far but on a dimpled ball, the air gets stuck for a much longer duration hence carrying it much farther.
Due to this, Golf balls started having dimples on their face. So, dimples might be imperfections, but they do serve a purpose!!