You’ll have to use different function for that.
wp_get_attachment_url
returns a full URI for an attachment file and it doesn’t know what type of attachment it is. It makes no sense to generate thumbnail for .zip od .txt files, so this function doesn’t allow you to get thumbnail url.
On the other hand, wp_get_attachment_image_url
knows that the file is an image, so you can tell it which size you want to get:
wp_get_attachment_image_url( int $attachment_id, string|array $size="thumbnail", bool $icon = false )
As you can see, second param is the size:
$size (string|array) (Optional) Image size to retrieve. Accepts any
valid image size, or an array of width and height values in pixels (in
that order).Default value: ‘thumbnail’