In order to retag Docker Image pushed with tag "latest" originally then you need to put a new tag here .
Docker Command to rename a tag is :
docker tag <old_tag> <new_tag>
where <new_tag> should be
repository:tag
- repository : "502341150717.dkr.ecr.us-east-2.amazonaws.com/app_app"
- tag : "dev.latest" or "prod.latest" (or anything else except "latest")
Hence the command that should work will be :
docker tag app_app:latest 502341150717.dkr.ecr.us-east-2.amazonaws.com/dev.latest
FYI : "app_app" is the name of your ECR Repository where images are stored and it is not the name of your image as mentioned in the comment's. Your original image was tagged as 'latest' and your are renaming it to 'latest' again, hence it doesn't work for you.