You should be able to automatically shoot the correct number of shots as per your old D80.
I have a D7500 and have been regularly been shooting scenes using bracketing, and it shoots the complete set of images and then stops.
A typical bracketing solution for me is:
Hold down the BKT button, and use the "Main command dial" (rear dial)
to select the number of shots. Also use the "sub command dial"
(front dial) to select the EV separation. (Currently I am using
5F/1.0 to shoot 5 shots that are -2, -1, 0, +1, +2 EVs around my base
Select either CL or CH on the "Release mode
dial". (I am normally using CL for my subjects)
Doing that is all that I need to do to shoot the desired number of shots when I hold down the shutter release.
Could you have modified other bracketing settings in the Custom menu like the d1 CL mode shooting speed, or the d2 Max continuous release? etc. I'd recommend doing a factory reset on your camera and setting up bracketing again.
Finally, if you don't firmly hold down the shutter release during a bracketing sequence then the camera will stop taking that sequence. That actually happened to me this morning.