The Croatian side did well to restrict City to just two but second-half goals from Sterling and Foden ensured a club record fifth consecutive Champions League home win. With the result, City top Group C with two wins from two.
City squandered a host of chances in the opening 25 minutes and had to wait until Sterling's introduction after half-time for the deadlock to be broken. On 65 minutes, Rodri released Riyad Mahrez down the left and the Algerian crossed low for Sterling to hammer home from close range.
Foden had only been on the pitch a matter of minutes when he drilled Sterling's pass into the corner of the net with the last kick of the game to double the margin of victory.
When Pep Guardiola needed a goal he turned to Sterling and it worked. The England winger has got nine already this season and is well on course to better the 25 he bagged last season. His goal here was a goalscorer's finish, making sure he was in the right position to tap in Mahrez's cross from close range.
It's two wins from two in the Champions League this season and the only negative was that the game wasn't put to bed earlier. It could have been 5-0 after 25 minutes had City taken their chances. They have been wasteful at times this season and Guardiola will want to make sure it does not develop into a habit.
Manager rating out of 10
8 -- There is nothing wrong with a manager's decision-making if his substitute scores the first goal of the game 10 minutes after coming on. It helps if you have got players of Sterling's quality to bring off the bench but the game could have become nervy if it had stayed 0-0 for much longer and Guardiola deserves credit for finding a solution.
Player ratings (1-10; 10 = best, players introduced after 70 minutes get no rating)
DF Joao Cancelo, 6 -- Making just his second start after his summer move from Juventus, he didn't have as much joy going forward as Benjamin Mendy on the opposite side.
DF Benjamin Mendy, 7 -- Still looks a little rusty but provided a constant attacking threat with his bursts forward from left-back.
DF Fernandinho, 7 -- Asked again to fill in at centre-back, his positioning was good, and he helped create the opening goal by pushing up into midfield.
MF Rodri, 7 -- Took a heavy fall early on but was able to continue. Made a perfectly-weighted pass into Mahrez's channel in the build up to Sterling's goal.
MF Ilkay Gundogan, 7 -- Came closest to breaking the deadlock in the first half with a shot that cannoned back off the crossbar.
MF David Silva , 7 -- Very clever around the penalty area but missed a sitter from seven yards that he managed to push past the far post.
FW Bernardo Silva, 6 -- Could have scored twice in the first 15 minutes, first with a shot from the centre of the penalty area that flew over the bar and again with a volley moments later.
FW Riyad Mahrez, 7 -- Had been quiet before running onto Rodri's pass to cross for Sterling to tap in from two yards out.
FW Sergio Aguero, 6 -- Had the first clear chance of the game when he rounded Dinamo goalkeeper Dominik Livakovic but it wasn't his night.
FW Raheem Sterling, 8 -- Made the breakthrough off the bench with a goal and an assist, showing again why he has become of the game's top players.
FW Gabriel Jesus, N/R -- Got a quick run out after scoring at the weekend.
MF Phil Foden, N/R -- Came on in injury time but had enough time to score his eight hgoal for the club.