chimera: fix rename into a file

fix confitions when file is remove into an existing file
as a parent.

Ticket: #8250
Acked-by: Paul Millar
Target: master
Require-book: no
Require-notes: no
(cherry picked from commit 119ecfe92c1a69925ad31934f7517421e3f74405)
(cherry picked from commit 1287a28a057c233b9e9c7d93876e4593d50343f4)
Signed-off-by: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de>