fix(model): fix replacement of the root element