 We see here that Jesus, Mary, and Joseph, they are far from lawbreakers. They really, really want to attend to the ordinances of God. And technically, Mary doesn't need any kind of purification, but that's partially why she is there. Because she's given birth, she would be called ritually unclean and needed to make a sacrifice for her purification. And Joseph, too, because he assisted in the birth, he would have been considered unclean