I don’t think she has a last name as we understand it. It would have been in relation to her father (like how Jesus calls Peter “Simon bar Jonah”: Simon, son of Jonah). So technically she’d be “Mary bat Joachim” (Mary, daughter of Joachim) I guess?
Surnames did not really exist in the ancient Middle East, not in the way we know them. There is a very good reason Jesus is often referred to as “Jesus of Nazareth”.
She would have been “Mary, the daughter of Joachim” or “Mary, the wife of Joseph the Carpenter” (similar to her cousin “Mary, the wife of Cleophas”) or maybe “Mary of Nazareth”.
DISCLAIMER: Catholic Answers has turned over the archive to Catholic-Questions.org and no longer owns, manages, or moderates the forums. For additional apologetics resources please visit www.catholic.com.