createIndex (name, fieldList, opts) {
    if (utils.isString(name) && fieldList === undefined) {
      fieldList = [name]
    }
    opts || (opts = {})
    opts.hashCode || (opts.hashCode = obj => this.recordId(obj))
    const index = (this.indexes[name] = new Index(fieldList, opts))
    this.index.visitAll(index.insertRecord, index)
  }
Create a new secondary index on the contents of the collection.

@example
// Index users by age
collection.createIndex('age');

@example
// Index users by status and role
collection.createIndex('statusAndRole', ['status', 'role']);

@method Collection#createIndex
@since 3.0.0
@param {string} name The name of the new secondary index.
@param {string[]} [fieldList] Array of field names to use as the key or
compound key of the new secondary index. If no fieldList is provided, then
the name will also be the field that is used to index the collection.