'Creates a volume.'

def create_flexvol(self, flexvol_name, aggregate_name, size_gb, space_guarantee_type=None, snapshot_policy=None, language=None, dedupe_enabled=False, compression_enabled=False, snapshot_reserve=None, volume_type='rw'):

    api_args = {'containing-aggr-name': aggregate_name, 'size': (six.text_type(size_gb) + 'g'), 'volume': flexvol_name, 'volume-type': volume_type}
    if (volume_type == 'dp'):
        snapshot_policy = None
    else:
        api_args['junction-path'] = ('/%s' % flexvol_name)
    if (snapshot_policy is not None):
        api_args['snapshot-policy'] = snapshot_policy
    if space_guarantee_type:
        api_args['space-reserve'] = space_guarantee_type
    if (language is not None):
        api_args['language-code'] = language
    if (snapshot_reserve is not None):
        api_args['percentage-snapshot-reserve'] = six.text_type(snapshot_reserve)
    self.send_request('volume-create', api_args)
    if (dedupe_enabled or compression_enabled):
        self.enable_flexvol_dedupe(flexvol_name)
    if compression_enabled:
        self.enable_flexvol_compression(flexvol_name)
