I study names for fun, because I’m a dork.
So, back in the sixth century, the Visigoths were kinda “in charge” in Spain, having been allowed to move in by the Romans in exchange for military service. The Visigoths were a Germanic people. The last Arian Christian king, Liuvigild, had two sons: the younger was Reccared, and the elder Hermenegild.
Reccared and Heremengild were associated with the King formally, thus ensuring a line of succession, and each were given areas of regency in which to rule.
Arian Christianity states that Jesus (the son of God) was subject to God, not on “equal footing” with him as it were. It’s based on the teachings of Arius, if you’d like to read more about it.
Hermenegild, after marrying and gaining his regency, converted to Chalcedonian Christianity (his wife’s religion), and started appointing Chalcedonian bishops in his regency. Chalcedonian Christianity had different ideas about how the divinity of Jesus worked. You can look it up if you like.
Hermenegild’s wife was told by her family to reject her father’s religion and go with her husband’s family’s. She resisted. Hermenegild was ordered by his father Liuvigild to convert back to Arian Christianity. He said no.
Liuvigild was not best pleased. He appointed NEW bishops, Arian ones, and Hermengild had his regency revolt against Dad. So dad paid off Hermenegild’s mercenary troops to make them go home, banished Hermenegild and later had him executed.
The names “Mendez”, “Menendez”, or “Mendes” are Spanish homages to Hermenegild, who was later considered a martyr and sainted by the Catholic church for not denying the divinity of Christ.