Changing the behavior of the red number on the Dock
Mail does not allow customisation of the app's badge in this way. You can provide feedback to Apple regarding this here:


https://www.apple.com/feedback/macosx.html