For NextJS 15, I just removed the rewrite logic in Amplify and it works perfectly.
Apparently in Newer version of Next JS handles routes internally in Amplify so just remove the rewrites.