There may be questions to answer when it comes to their domestic form, but everything seems to fall into place for Leicester City when the Champions League anthem is played. On a night when his team showed the character and spirit that Claudio Ranieri had demanded, Riyad Mahrez scored the only goal of the game to register a third successive victory in the competition and move the English champions within touching distance of the knockout stage.

Remarkably Leicester have now accumulated more points in the Champions League than they have in the Premier League, despite playing five games fewer. They are enjoying the view from the top of Group G, five points clear of Copenhagen and Porto, who are level for second place, and have yet to concede a goal in Europe’s premier club competition.

Mahrez has taken to the Champions League better than anyone in a Leicester shirt and it was a wonderful piece of instinctive skill that provided the defining moment in a tight game. Islam Slimani, his Algerian team-mate, nodded the ball back across goal and Mahrez, with a lovely flick on the volley, beat Robin Olsen, the Copenhagen goalkeeper, from the edge of the six-yard box.

This was Copenhagen’s first defeat in 24 matches and that long unbeaten record would have remained intact but for an outstanding piece of goalkeeping from Kasper Schmeichel in the 90th minute. Andreas Cornelius’s low shot from 12 yards seemed to be arrowing towards the bottom corner only for Schmeichel to stretch out a hand and superbly claw the ball away.

For Schmeichel, who was born in Copenhagen and playing against a Danish team for the first time in his career, it felt like a special moment and he was entitled to all the praise that came his way afterwards. The home supporters were still singing his name as he left the field and Stale Solbakken, the Copenhagen manager, could be forgiven for cursing what might have been.

The Danish champions looked like an accomplished side and it was easy to see how they had put together that run of impressive results, dating back to 22 May. For the opening half an hour they moved the ball with confidence, dominating possession and frustrating a Leicester team that seemed far too reliant on the long ball over the top. “More direct than expected” was Solbakken’s verdict when asked whether Leicester’s approach was what he had anticipated.

Mahrez’s goal, which had not exactly been coming, settled Leicester and they improved in the second half, when they were unlucky not to score a second. Slimani was unfortunate to be flagged offside when he turned in Marc Albrighton’s cross from the left at the second attempt, with TV replays showing the striker was level.

While Mahrez was Leicester’s most dangerous player, Danny Drinkwater became increasingly influential as the game went on. Jamie Vardy caused Copenhagen problems in the first half with his running in the inside-left channel and although his goal drought continues, the England international will take encouragement from his involvement in Mahrez’s winner. It was Vardy’s inswinging cross from the left that picked out Slimani, who had drifted towards the far post. With Mathias Jorgensen guilty of ball-watching, Mahrez darted in front of the central defender to expertly steer Slimani’s knock-down into the net.

Mahrez and Slimani were two of four changes made to the Leicester side that lost heavily at Chelsea on Saturday, with Andy King and Danny Simpson also restored to the starting XI. Ranieri had, by his own admission, prioritised this fixture, but little went Leicester’s way in the first half other than Mahrez’s goal, and they were fortunate not to concede just before half-time.

Set-pieces have been a problem for Leicester this season and once again their weaknesses in that area were exposed on a corner. Cornelius, who endured a miserable time at Cardiff during the 2013-14 season, when he arrived as their club-record signing and returned to Copenhagen only six months later without scoring, got away from Robert Huth but his glancing header flashed inches wide of the far upright.

It was not the only occasion that Leicester were stretched defensively in the first half. Schmeichel had to be alert to block Federico Santander’s close-range attempt in the opening minutes, Youssef Toutouh’s shot skimmed the roof of the net later in the half and an alarming amount of space opened up for the Copenhagen full-backs to exploit at times.

Leicester, however, looked sharper after the restart and attacked with much more conviction. Mahrez drilled a left-foot shot that Erik Johansson blocked and moments later came Slimani’s disallowed goal, when Peter Ankerson, the Copenhagen right-back, appeared to be playing him on.

It was a reprieve for the visitors and one that they very nearly took advantage of in the closing stages. Santander found room on the left to dig out a cross that picked out Cornelius for what looked to be a certain goal when he connected sweetly with the ball. Schmeichel, however, showed his class to keep the shot out.