If you use a third party alarm application, that application may not properly register the alarm with the system Alarm manager. If it doesn't register that alarm, Doze really couldn't care less how much you need to wake up at 6:00 AM, it will never fire. Doze only allows alarms that are properly registered.
Easiest way to check if your alarm app properly registers is to look at your status bar. If you have an alarm clock icon next to your signal cluster, you have a system alarm set... and Doze will allow it to wake your phone (you'll also see an alarm icon on the lock screen and notification shade). If you DON'T see any of these alarm messages, then the app won't work with Doze.
Two solutions :
1) Go to Settings - Battery - Battery Optimizations (in three dot menu) - All Apps... find your alarm app and set it to "Don't optimize". This SHOULD tell Doze to ignore the app and let it do its thing.
2) Dump the alarm app and use one that properly registers the alarm. This is tricky because they don't come out and say it o the Play Store. Obviously, the stock alarm clock works. Timely (which was bought by Google) is another.