'Creates a group.'

def create_group(self, context, group):

    if (not volume_utils.is_group_a_cg_snapshot_type(group)):
        raise NotImplementedError()
    if (group.volume_type_ids is not None):
        for volume_type in group.volume_types:
            allow_type = self.is_volume_group_snap_type(volume_type)
            if (not allow_type):
                msg = _('For    a    volume    type    to    be    a    part    of    consistent    group,    volume    type    extra    spec    must    have    consistent_group_snapshot_enabled="<is>    True"')
                LOG.error(msg)
                raise exception.InvalidInput(reason=msg)
    pool = volume_utils.extract_host(group.host, level='pool')
    domain = self.get_domain(pool)
    cg_name = self._get_3par_vvs_name(group.id)
    extra = {'group_id': group.id}
    if (group.group_snapshot_id is not None):
        extra['group_snapshot_id'] = group.group_snapshot_id
    self.client.createVolumeSet(cg_name, domain=domain, comment=six.text_type(extra))
    model_update = {'status': fields.GroupStatus.AVAILABLE}
    return model_update
