I’m the wrong person to ask really. I can advise, however, to post to the developer mailing list if you encounter any bumps in the dev road. @axeld is the one working on the mail system last and he’ll read it there, but probably not here in the forums.
Other than that, to test your custom mail_daemon you have to stop the launch_daemon from restarting the original with
launch_roster stop x-vnd.Be-POST.
Also, be aware that there are several add-ons (in
/boot/system/add-ons/mail_daemon) and the libmail.so (in
/boot/system/lib/libmail.so) that you may have to replace with your version too, by putting yours into the /system/non-packaged/… hierarchy.