'Creates a volume.'

def create_volume(self, volume):

    data = {'vol-name': volume['id'], 'vol-size': (str(volume['size']) + 'g')}
    self.client.req('volumes', 'POST', data)
    consistency_group = volume.get('consistencygroup_id')
    if volume.get('group_id'):
        consistency_group = volume.get('group_id')
    if consistency_group:
        self.client.add_vol_to_cg(volume['id'], consistency_group)
