Like most cameras, smartphones are a compromise. While convenient to carry and easy to use, they generally offer less creative control and image quality than DSLR and mirrorless cameras.
In order to rename your image in your IPhone, you will need to save the image as a file.
In order to rename your image on a Samsung, you will need to save the image as a file. Go to Gallery > tap your photo > tap the three vertical dots at bottom right of screen.