If you have a gas grill instead of charcoal, you just want to avoid cooking them over direct heat. So if you have multiple burners, keep one side off and put your potatoes on that side. If you keep the lid closed, you're basically turning your grill into an oven. Just keep an eye on the thermometer. You want 200 C or 400 F, roughly.