Defender Michael Hector scored the only goal of the game for Town, heading home a Billy Jones corner midway through the second half.
Despite defeat, the already-promoted Gills remain six points clear of second-placed Port Vale with just two games remaining.
"Our players battled and we had a few half opportunities," Allen said. "We did alright and the players performed well but Cheltenham did very well.
"One little error has cost us the game and we will have to live with that. We came here to win and I'm disappointed that we didn't.
"But the players have given everything. It would have been nice to get a goal at the end to go up as champions but we can look forward to next Saturday when a win will make us champions. We need to put in a performance in front of our home supporters to make it happen."
Allen came in for some abuse from a section of the Cheltenham crowd having managed the Cotswold club for more than a year before leaving in 2009.
"I don't give a monkey's what the supporters think of me - I love this place and it's always been very special to me," Allen added. "All the people I worked with behind the scenes know I did the best I could and they are the people who matter."
- Sports & Recreation