It's possible to let the buyer enter a custom price by selecting "Donation" when creating a ticket type. You can set a minimum price as well as a suggested price, first shown to the donator. The minimum price can be zero, which lets the buyer get the ticket for free.
This is what your buyer will see during the checkout: