Moving files to related subdirectories