In a large pot, bring salted water to a boil. Add the diced potatoes and cook for about 10-12 minutes, or until tender. Drain and set aside.
In a large skillet, heat the olive oil over medium heat. Add the chopped onion and sauté for about 3-4 minutes until translucent.
Add the minced garlic to the skillet and cook for an additional 1-2 minutes until fragrant.
Pour in the heavy cream and add the dried rosemary, salt, and pepper. Stir to combine and let it simmer for about 5 minutes.
Gently place the cod fillets into the skillet, spooning some of the cream sauce over the top. Cover and cook for about 5-7 minutes, or until the cod is cooked through and flakes easily with a fork.
Stir in the cooked potatoes and lemon juice, mixing gently to combine everything. Cook for an additional 2-3 minutes to heat through.
Serve hot, garnished with fresh parsley.