WhatsApp voice call overrides iPhone's "do not disturb"
Solution 1:
This is intended behaviour. Do Not Disturb only enables Apple's features like phone and messages. It does not affect third-party applications.
From this Apple Discussion:
It has nothing to do with Apple's software. Do not disturb only affects Apple's core iOS features - the telephone app, the messaging app and iOS notifications service. It does not interact with or affect third party apps.
If you want Whatsapp to implement the feature you need to contact them:
If you want WhatsApp to implement something similar, then you need to suggest it to the WhatsApp developers. Or, close WhatsApp at night, and disable it in background app refresh in settings.
To provide a similar setting on Whatsapp you can close it at the desired time and turn on background app refresh which will prevent it from updating and receiving messages.
To turn off background app refresh
Go to Settings -> General -> Background app refresh and turn of Whatsapp.
To completely turn all apps of from refreshing click at the top where it says background app refresh and click off.