Preheat your oven to 375°F (190°C).
In a large pot, bring salted water to a boil. Add the cubed potatoes and cook until tender, about 15-20 minutes. Drain and set aside.
In a skillet, heat olive oil over medium heat. Season the cod fillets with salt and pepper, then add them to the skillet. Cook for about 3-4 minutes on each side, or until the fish is cooked through and flakes easily. Remove from the skillet and set aside.
In the same skillet, add minced garlic and cook for 1 minute until fragrant. Pour in the heavy cream, add rosemary, and lemon juice. Stir and let it simmer for 3-4 minutes until slightly thickened.
While the sauce simmers, mash the cooked potatoes with butter and milk until smooth. Season with salt and pepper to taste.
Place the cod fillets back into the skillet with the cream sauce, spooning the sauce over the fish. Let it cook for an additional 2-3 minutes to heat through.
Serve the cod on a plate with a generous scoop of garlic mashed potatoes and drizzle with the creamy rosemary sauce.