Sounds like you need rsync
, with the merge option, not overwrite. If you are using any decent and recent version of linux, you should have rsync installed by default.
source: /home/xyz/public_html/photo/ABC/Something/something/xyz.jpg
target: /home/ABCDE/public_html/photo/ABC/Something/something/xyz.jpg
rsync -avibu --ignore-existing /home/xyz/public_html/photo/ /home/ABCDE/public_html/photo
On this command I selected the top level directory randomly. You may want to modify according to your needs. Also pay attention to the trailing "/" on both source and destination. Otherwise, placement of files might be a level of directory off.
-b makes rsync backup files that exist in both folders, appending ~ to the old file. You can change the ~ suffix with --suffix string_of_your_choice -u makes rsync transfer skip files which are newer in destination than those in source