serializeToDatabase(role) {
    const serializedRole = {};

    Object.keys(role).forEach((key) => {
      if (key !== "_id" && key !== "restrictedTo") {
        serializedRole[key] = role[key];
      }
    });

    return serializedRole;
  }
From a Role object, returns an object ready to be persisted

@param {Role} role
@returns {object}