Yes, fill the car up and then go into the shop/office to pay, either by card or by cash. Make a note of your pump number before you go to pay.
Occasionally after hours (by which I mean in the small hours of the morning), they might ask you to pay first, although not necessarily. At normal times this would be unusual to say the least.
Just make sure you use petrol (Benzin) or diesel (Diesel) as your car requires.