'Creates a network subnet within a VPC.
:param      vpc_id: The ID of the VPC that the subnet should be
associated with
:type       vpc_id: ``str``
:param      cidr_block: The CIDR block assigned to the subnet
:type       cidr_block: ``str``
:param      availability_zone: The availability zone where the subnet
should reside
:type       availability_zone: ``str``
:param      name: An optional name for the network
:type       name: ``str``
:rtype:     :class: `EC2NetworkSubnet`'

def ex_create_subnet(self, vpc_id, cidr_block, availability_zone, name=None):

    params = {'Action': 'CreateSubnet', 'VpcId': vpc_id, 'CidrBlock': cidr_block, 'AvailabilityZone': availability_zone}
    response = self.connection.request(self.path, params=params).object
    element = response.findall(fixxpath(xpath='subnet', namespace=NAMESPACE))[0]
    subnet = self._to_subnet(element, name)
    if (name and self.ex_create_tags(subnet, {'Name': name})):
        subnet.extra['tags']['Name'] = name
    return subnet
