Captain Azam hit 85 from 49 balls and Rizwan 63 from 41 in a Pakistan record total of 232-6.
England lost four wickets in the first seven overs, and its hopes flickered thanks only to Liam Livingstone with a career-best 103. But he was seventh man out in the 17th over and England was soon all out for 201 with four balls left.
England's senior stars returned from self-isolation but failed to copy the domination their second string achieved against Pakistan in the one-day international series.
While England's big boys sat out the ODIs because of a coronavirus outbreak, a makeshift side of county players and fringe internationals overwhelmed Pakistan 3-0. With isolation over, only four of the B side were retained and none managed to contribute much.
Middle-order bat Livingstone, from the main squad, shone with his century in a losing effort.
Pakistan rebounded from the ODI humiliation, and after being forced to bat first. Babar and Rizwan received good support from Sohaib Maqsood, 19 from 7, Fakhar Zaman, 26 from eight, and Mohamad Hafeez 24 from 10 as they easily eclipsed their previous highest T20 score of 205 in 2018 and last April.
England's chase was undermined early when opener Dawid Malan and Moeen Ali were out for 1s by 48-3.
Livingstone's 42-ball century, the fastest by an Englishman in T20s, arrived with his ninth six -- more than the rest of the team combined -- but he was out next ball to a boundary catch by Shaheen Shah Afridi at 183-7 in the 17th over, and so went England.
Livingstone was one of five catches on the boundary, two of them taken by Afridi, who also contributed 3-30 including a caught and bowled.
Shadab Khan also starred in the field with 3-52, a catch, and a direct-throw run out of Tom Curran.
The second T20 is on Sunday at Leeds. (AP)