You cannot fix the rotation and only refine for the translation with SOLVEPNP_ITERATIVE.
But you can for sure code it yourself (or modify the OpenCV code):
- 16. Gauss–Newton method
- Pose Estimation for Augmented Reality: A Hands-On Survey
- since the Jacobian when optimizing for the full 3D pose is:
- you can also optimise for just the translation part