Allegri was sacked by the San Siro outfit on Monday after a series of dismal results left the club languishing in the bottom half of Serie A, with Clarence Seedorf set to be confirmed as his replacement.
Coach Mauro Tassotti has taken caretaker charge in the meantime, and will have been pleased with what he saw as Giampaolo Pazzini - making his first start since April - inspired Milan to qualification for the quarter-finals.
The forward provided the assist as Robinho broke the deadlock with a headed effort in the 28th minute, before Pazzini himself doubled the advantage with a volley three minutes later.
And Milan were three up two minutes after the break, as Keisuke Honda reacted quickest to a Nicola Leali parry from a Riccardo Montolivo effort to net his first goal for the club.
New boss Seedorf arrived in the stands in time to watch the last 20 minutes, but the only goal he saw was a stoppage-time consolation strike for Milan's second-tier opponents courtesy of Nicola Ferrari.
In the day's early kick-off, second-tier side Siena pulled off a shock 4-1 victory at Serie A's bottom club Catania.
Sebastian Leto put the hosts ahead inside the opening five minutes, but Michele Paolucci equalised for Siena to send the sides in level at the break.
Francesco Valiani's glancing effort on the hour mark put the visitors in front, and stoppage-time goals from Nico Pulzetti and Valerio Rosseti made sure of their progression to the last eight.
Get the best features, fun and footballing frolics straight to your inbox every week.
Thank you for signing up to Four Four Two. You will receive a verification email shortly.
There was a problem. Please refresh the page and try again.