Hi Arijit,
Just a hint. Maybe create 2 mappings as follows:
:
1) From your source to target structure (File to File)
2) From your source to mail structure ( File To Mail)
And then use BPM - SWITCH step for conditional routing.
I have not tried it, but I guess you can try and see.
Regards,
Mateen