One way of visualising this is to imagine that the path shown sticks to the cube, with the path moving rather than the cube. This produces the same result, but might be easier to visualise.
Then, 1 attaches to the base of the cube, 2 attaches to the right hand face and 3 attaches to the top. 4 attaches to the back face and 5 to the left hand face. 6 then attaches to the bottom face and 7 to the front face.
This means both 1 and 6 are on the same face, so the same face of the cube rolls onto 1 and 6.