Madrid looked poised to have to settle for a draw against their neighbours after Jorge Molina cancelled out Karim Benzema's first-half opener.
Ronaldo had failed to score in his first three league appearances this season, and somehow missed a glorious chance with the goal at his mercy from a yard out late on.
But he quickly atoned for that astonishing display of profligacy, firing in Isco's superb lofted ball on the half-volley five minutes from time.
And speaking at his post-match media conference, Zidane said: "It was important that he scored his first [in the league], from there we will see, but I am happy for him and for Benzema.
"We have suffered a lot but it is normal. We know that in La Liga we are going to suffer in all the matches because there is a rival that wants to put you in difficulties.
"The good thing is that we played a good match, the first half was phenomenal with how we had the ball and with our chances.
"We have achieved the three points, which is what was most important."
Asked about the achievement of winning his 100th game at the helm, Zidane replied: "Nothing has changed, I'm always the same, better to win match 100, no doubt, it's a good memory."