framework/web/XmlResponseFormatter.php
protected function getValidXmlElementName($name)
    {
        if (empty($name) || is_int($name) || !$this->isValidXmlName($name)) {
            return $this->itemTag;
        }

        return $name;
    }
protected function getValidXmlElementName($name)
    {
        if (empty($name) || is_int($name) || !$this->isValidXmlName($name)) {
            return $this->itemTag;
        }

        return $name;
    }
Returns element name ready to be used in DOMElement if
name is not empty, is not int and is valid.

Falls back to [[itemTag]] otherwise.

@param mixed $name
@return string
@since 2.0.12