The Rossoneri coach stated that he is not interested in the Italy international, while revealing that he plans to call time on his career in 10 years
The Rossoneri had been suggested as a potential destination for the Italy international after City coach Roberto Mancini dropped a hint towards the end of the season that the controversial striker could move on during the summer.
The 21-year-old has since confirmed that he will not leave the Premier League champions, comments that have also been mirrored by Mancini, and Allegri has declared that he is not interested in signing the former Inter man.
"Mario will not come to Milan," he told Chi magazine. "I hope that he matures. A player's career is short.
"He must not regret the mistakes he has made."
The 44-year-old has also revealed that he does not plan to drag on his coaching career, but admitted that he would like to guide Italy's national team before retiring.
"I will stop in 10 years," Allegri revealed. "I started [in Serie A] when I was 40, I will retire at the age of 55.
"Fifteen years as a coach is enough and then I will go. I admit that I would like to coach Italy."