The two clubs are separated by 81 places in the Football League pyramid and, with the Bluebirds buoyed by Sunday's 3-2 victory over Manchester City and Stanley winless in League Two, few gave the hosts much hope.
"That could have been a potential banana skin tonight if we hadn't gone out and been professional," said Mackay, who rested all of the XI which started against City.
"We knew they were going to try and pack the area and make it difficult for us. We had to keep shifting the ball from side to side and eventually little gaps open up, which is what happened.
"As the second half wore on we were increasingly influential and looked as if we were going to score."
It needed a moment of brilliance from Maynard to break the deadlock as the former Bristol City striker flicked the ball over his head before coolly slotting home on the hour.
Gestede's first-time finish moments later was another indication of the Premier League outfit's class and, particularly with summer signing Andreas Cornelius coming off injured in the first half, the form of his strikers pleased Mackay.
The Bluebirds boss, who does not believe Cornelius' injury is too serious, added: "Nicky Maynard's first goal was fantastic. The second one as well; a great ball from Jordon Mutch and the finish from Rudy Gestede as well.
"I'm delighted for the boys tonight. They applied themselves really well and if they hadn't, that could have caused us a problem."
- Sports & Recreation
- Nicky Maynard
- Rudy Gestede
- Manchester City