Irish and Scottish names are hard for a lot of people. Here's a nice blog post from Barry R McCain at McCain's Corner:
"Most people are familiar with male surnames in Gaelic; Ó means “descendant of” and Mac means “son of.” Mag is an alternative spelling of Mac and was sometimes used when the name that follows it began with a vowel. The ladies used a similar system. Girls and unmarried women with surnames that began with Ó would have Ní before their surname. Girls and unmarried women whose family surname began with Mac would use Nic."
"Married women would take their husbands names, but the prefix form was different than the male form. Ó became Uí and Mac became Mhic. This name change did not always hide the surname of the woman’s father however. In traditional Gaelic society some women were known by their maiden names due to the strong sense of family and clan affiliation."
Two examples from the mid to late 1500s. See ...
Irish & Scots Female Ancestor Names in Primary Sources
http://barryrmccain.blogspot.com/2016/10/irish-and-scots-female-anc...