The javascript property that indicates what the tag is tagName.
Once you resolve the locator to an element you could evaluate the property, something like this:
tagName = element.evaluate("el => el.tagName")