For the upgrade of metadata XML format from legacy ISO 19139:2007 to newer ISO 19115-3:2016, all classes in org.apache.sis.metadata.iso package and sub-packages have their JAXB annotations upgraded except ImmutableIdentifier. The later is used mostly by sis-referencing, which is still (un)marshalled according GML 3.2. The consequence is that DefaultIdentifier and ImmutableIdentifier - which are supposed to be two implementations of the same Identifier interface - now use two different set of JAXB annotations. This may be a cause of confusion.
We should upgrade JAXB annotations to ISO 19115-3:2016 on ImmutableIdentifier too, with verification that it preserves compatibility with GML 3.2 (un)marshalling in sis-referencing.
Update (August 2019): an alternative is to remove JAXB annotations completely for that particular class. See comments.