Peel potatoes. Cook them in salted water for about 15 minutes until nice and soft. Strain them.
Grease your baking tray with olive oil. Cut potatoes in half and put them in a tray. No worries if they break apart, they will be delicious nonetheless.
Crush unpeeled garlic cloves with a knife. Add them to the tray. Push them between potatoes in different places in the tray. Add a splash of olive oil and sprinkle with salt.
Bake at 200°C for 1 hour. After that, add rosemary. If you add it at the beginning it will get burnt and won't be as tasty as it should be.
After that bake for additional 15-20 minutes with ventilation on. You might want to check potatoes after 10 minutes so they don't get burnt.