And his side's continued inadequacies were evident in a performance littered with defensive errors which enabled the home side to move above Cagliari into fifth place.
Pioli named the same side that had stuttered to a draw with Lecce last week and they had the first chance with Rafael Leao firing wide before a Lucas Paqueta effort was ruled out for offside.
But Milan's early promise soon faded and they fell behind after 38 minutes. Visiting keeper Gianluigi Donnarumma had saved brilliantly to deny Zaniolo but from the resulting corner, Dzeko was left completely unmarked at the far post and headed home.
But just three minutes later, Milan squandered possession and Dzeko teed up Zaniolo who rifled home what proved to be the winning goal from the edge of the box.
Substitute Gianluca Mancini could have extended Roma's lead from another corner, Pastore had an effort ruled out for offside, and Donnarumma saved well to deny Zaniolo.
Milan came close to grabbing a scarcely deserved draw in stoppage time but midfielder Hakan Calhanoglu drilled his shot into the side-netting.