code: public function addTextInput($id, $label, $comment, $required = true)
      {
          $this->children[$id] = [
              'id'            => $id,
              'type'          => 'text',
              'translate'     => 'label comment',
              'showInDefault' => 1,
              'showInWebsite' => 0,
              'showInStore'   => 0,
              'sortOrder'     => count($this->children),
              'label'         => $label,
              'comment'       => $comment,
              'validate'      => ($required == true) ? 'required-entry' : '',
              '_elementType'  => 'field',
              'path'          => self::BASE_CONFIG_PATH . '/' . $this->id
          ];
      }
docs: Insert text input for Modly config
  
  @param $id
  @param $label
  @param $comment