If the customer is not sure whom they want to give the gift card to, at the time of gift card sale you can enter the details of the customer purchasing it in the receiver details and proceed with the payment.
The customer who purchased the gift card will receive an email with the gift card code which they can later share with the person they want to gift it to.
When a gift card has been purchased, It is not limited to the person who has received it. The gift card can be used by any customer with the gift card code. Once a gift card is used by a customer to make a purchase, It will be registered to that customer's profile and the system will not allow any other customer to use that gift card.
To learn how to sell a gift card you can refer to the article below