public PsiElement setName(String newName) {
        ASTNode node =  this.getNode().getFirstChildNode();
        if (node != null) {
            SdIdentifier elementName;
            if (this instanceof SdIdentifierVal) {
                elementName = SdElementFactory.createIdentifierVal(this.getProject(), newName);
            } else { // this instanceof SdIdentifierWithDashVal
                elementName = SdElementFactory.createIdentifierWithDashVal(this.getProject(), newName);
            }
            ASTNode newNode = elementName.getFirstChild().getNode();
            this.getNode().replaceChild(node, newNode);
        }
        return this;
    }
This abstract class is used for methods' implementations for SdIdentifier. Connected with "mixin" to IdentifierVal and 
IdentifierWithDashVal rules in sd.bnf

@author Shahar Ariel
integration/intellij/src/main/java/ai/vespa/intellij/schema/psi/impl/SdIdentifierMixin.java