Go for September to November. The weather is cool, sunny, and breezy—perfect for walking 18 holes without breaking a sweat. March to May is also great if you like it a bit warmer.
Just avoid July and August unless you want to dodge storms, and skip the peak of winter if you don't like playing in the cold fog!