You can specify the Availability Zone in the resource's properties. Here's an example CloudFormation template to launch an EC2 instance in a specific Availability Zone:
Resources:
MyEC2Instance:
Type: AWS::EC2::Instance
Properties:
AvailabilityZone: us-west-2a
ImageId: ami-12345678
InstanceType: t2.micro