It's possible to climb the Machame route all year, but April, May, October and November are the rainy seaons, but nowadays climate change has made the rainy seasons less predictable. Broadly speaking January and February are the warmest months, April and May are the wettest months, June and July are the coolest months, and August and September are the driest months.
Consider also the moon cycles, summitting on a full moon generally means it will be busy and the route can get clogged. It is nice to climb by the light of the moon and stars but you might find yourself negotiating other people all the time.
Flight costs are also worth mentioning. During the high season at the start of the year flights can be 30% more than low season. Also consider if you want to go on a safari afterwards or visit Zanzibar, the best time of year to see animals is probably around August time (also the most expensive for flights again).