Media reports in Italy suggest Roma will turn to Allegri to replace the sacked Zdenek Zeman.
But Allegri appears to have ruled out such a prospect. Milan are up to fourth in Serie A, three points behind third-placed Lazio after a slow start to the season.
He said: “The interest of a great club like Roma is pleasing and it shows an appreciation for my work,” the tactician told the Messaggero.
“I’m honoured, but I’m also happy at Milan.”
Allegri's Milan deal expires at the end of next season.
Milan vice-president Adriano Galliani commented: "He’s a good tactician and we’ve always known that. He reminds me of Carlo Ancelotti, for how balanced he is.
“Roma can’t steal coaches from other clubs. He will still be the Milan boss next season.
“Milan were right to not make a coaching change when things were difficult this season. Other clubs would not have done the same.
“We’re climbing back up the table and fighting for the positions that we always have done. We’re now travelling at our pace from the last two seasons.”