title: Create database fields to an existing table when installing a module in Drupal 8
body: <p>I'm new to drupal and I need some help.</p>
  
  <p>I created a new module with name <code>user_extra</code>. Which create necessery table when Installing the module.</p>
  
  <p>But I also need to insert some database field in <code>'users_field_data'</code> table (<code>'user_extra_id'</code> and <code>'user_office'</code>)</p>
  
  <p>In <code>baseFieldDefinitions</code> I wrote all necessery database table fields for <code>user_extra</code> table.</p>
  
  <pre><code> public static function baseFieldDefinitions(EntityTypeInterface $entity_type) {
      // Standard field, used as a unique if primary index.
      $fields['id'] = BaseFieldDefinition::create('integer')
          -&gt;setLabel(t('Unit ID'))
          -&gt;setDescription(t('The unit ID.'))
          -&gt;setReadOnly(TRUE)
          -&gt;setSetting('unsigned', TRUE);
  
      $fields['uuid'] = BaseFieldDefinition::create('uuid')
          -&gt;setLabel(t('UUID'))
          -&gt;setDescription(t('The unit UUID.'))
          -&gt;setReadOnly(TRUE);
          .
          .
          .
      $fields['user_info'] = BaseFieldDefinition::create('string')
          -&gt;setLabel(t('User Info'))
          -&gt;setDescription(t("The User Info"))
          -&gt;setSetting('max_length', 255)
          -&gt;setDisplayOptions('form', array(
            'type' =&gt; 'string_textfield',
            'weight' =&gt; 10,
          ))
          -&gt;setDisplayConfigurable('form', TRUE);
       return $fields;
       }
  </code></pre>
  
  <p>When I install the module it inserts all values that I define in <code>baseFieldDefinitions</code>.</p>
  
  <p><strong>But I also need to create <code>'user_extra_id'</code> and <code>'user_office'</code> in <code>'users_field_data'</code> table with <code>setDisplayOptions</code> and <code>setDisplayConfigurable</code> options.</strong></p>
  
  <p>This is the commenting that I made in entity file</p>
  
  <pre><code>/**
   * @ContentEntityType(
   *   id = "user_extra",
   *   label = @Translation("user extra"),
   *   handlers = {
   *     "storage" = "Drupal\user_extra\UserextraStorage",
   *     "storage_schema" = "Drupal\user_extra\UserextraStorageSchema",
   *     "access" = "Drupal\user_extra\UserextraAccessControlHandler",
   *     "list_builder" = "Drupal\user_extra\UserextraListBuilder",
   *     "view_builder" = "Drupal\user_extra\UserextraViewBuilder",
   *     "views_data" = "Drupal\user_extra\UserextraViewsData",
   *     "form" = {
   *       "default" = "Drupal\user_extra\Form\UserextraForm",
   *       "add" = "Drupal\user_extra\Form\UserextraAddForm",
   *       "edit" = "Drupal\user_extra\Form\UserextraEditForm",
   *       "delete" = "Drupal\user_extra\Form\UserextraDeleteForm",
   *     }
   *   },
   *   admin_permission = "administer user_extra",
   *   base_table = "user_extra",
   *   entity_keys = {
   *     "id" = "id",
   *     "label" = "name",
   *     "uuid" = "uuid",
   *   },
   *   links = {
   *     "canonical" = "/admin/user_extra/{user_extra}",
   *     "add-form" = "/admin/user_extra/add",
   *     "delete-form" = "/admin/user_extra/{user_extra}/delete",
   *     "overview-form" = "/admin/user_extra/${user_extra}/overview",
   *     "edit-form" = "/admin/user_extra/{user_extra}",
   *     "collection" = "/admin/user_extra",
   *     "children" = "/admin/user_extra/{user_extra}/children",
   *   },
   * )
   */
  </code></pre>