The victory kept Zenit eight points ahead of Lokomotiv Moscow with just four games left to play.
As well as Azmoun's double, Samara skipper Taras Burlak put through his own goal with Igor Smolnikov adding a fourth.
Lokomotiv edged Yenisei Krasnoyarsk 2-1 to keep their slim hopes alive with Krasnodar, who beat CSKA Moscow 2-0, in third, three points further back.
Azmoun opened the scoring in the ninth minute, tapping home a cross by Yury Zhirkov.
In the 30th minute, Azmoun netted his second of the match and 12th of the season to join CSKA's Fyodor Chalov on top of the league scorers chart.
Five minutes later, a Artem Dzyuba shot was diverted into his goal by Burlak.
Samara refused to surrender, however, and left winger Denis Tkachuk scored twice within the space of four minutes to make it 3-2 at half-time.
But the visitors' hopes of a shock recovery disappeared in the 78th minute when Ramil Sheidaev was sent off for a second bookable offence.
Smolnikov rounded off the scoring in the first minute of injury time to secure Zenit's win.
"It was quite a surprise when Samara scored twice late in the opening period," said Zenit manager Sergei Semak.
"We felt the pressure until Smolnikov scored the fourth goal but nevertheless we won deservedly."
Reigning champions Lokomotiv opened the scoring at home to Yenisei Krasnoyarsk in the 67th minute when Valery Kichin sent the ball into his own net attempting to clear Alexei Miranchuk's cross.
Mikhail Kostyukov levelled in the 84th minute but four minutes later Anton Miranchuk found Jefferson Farfan and the Peruvian scored Lokomotiv's winner with an angled shot.