Mac Aodhagáin is a very fancy way of saying "son of Aodhagán". In the olden days in Ireland, people didn't have last names like we do now. Instead, they used a naming system called "patronymic," which means that your last name was based on your father's first name. So, if your dad's name was Aodhagán, then your last name would be Mac Aodhagáin, which means "son of Aodhagán".
It's kind of like when your teacher calls you "Johnny's dad" or "Samantha's mom" at school. Your teacher isn't using your first name, but she's using your parent's name to identify you. Same thing with Mac Aodhagáin - it tells us who your dad was, and by extension, a little bit about who you are.
This naming system was used in Ireland for a long time, but nowadays most people have last names that aren't based on their dad's name. But Mac Aodhagáin and other patronymic names are still used by some people who want to connect with their Irish heritage.