In the explanation Sukuna says he was going to use Mahogara as a "Role Model" to get past Infinity
so yeah, it seems like he let Mahogara adapt to Infinity and learned from it
and with this learning, he was able to cut space / infinite / the world itself with his CT