in your case the easiest way is to use homography transform which allows you to correctly transform planar object between different perspective views (map a poster to a wall; rectify a license plate, ...). If you use OpenCV, look at findHomography(), warpPerspective and perspectiveTransform();
(OpenCV) If your have 4 corners of a license plate in variable plateConrners, you can rectify it into rectifiedImage by:
Do read the blog for better understaning: https://medium.com/acmvit/how-to-project-an-image-in-perspective-view-of-a-background-image-opencv-python-d101bdf966bc