Just for absolute clarity, is the click happening when you depress the brake pedal while coming to a stop (but the car is still in motion) or does the click happen once the car has come to a complete stop and the suspension comes to rest? Likewise with the acceleration... Is the click sounding as you're releasing the brake to accelerate, before the car is actually in motion?
A "click" is very vague because it can have many sounds. A recording is always nice. If you're not moving the shifter, the brake pedal switch that MuranoSL2003 mentioned sounds like a good bet, or maybe a mechanism attached to the brake pedal (such as a linkage) is catching and clicking on or against something. Does it sound more like something electrical is turning off and on (engaging/disengaging), or is it like something is catching/snagging and releasing and making the noise? When you press or release the brake pedal and hear the click, is there also a vibration or any kind of sensation you can feel in your foot? I agree that getting close to the floorboard/firewall and using a hand to move the brake pedal is a good idea.
If you're parked in a garage and want to keep the car running and in D while checking for the noise, I would move the car all the way forward to the wall in front of it and use a small cushion or pillow between the bumper and the wall, then ease the car forward to keep the cushion pinned in place, then set the parking brake. When I've wanted to keep my 2003 in D while checking things, I used this method just in the off-chance the engine did some freaky thing and idled faster for a second that could send the car forward suddenly. By limiting the amount of forward movement, you greatly reduce the chance of damaging your car, the wall, and yourself. In a situation like this, where I'm on polished concrete, I wouldn't trust chocking the wheels.
I plan to put together a video of some things I've done to quiet noises in the engine compartment that aren't necessarily being heard inside the cabin. Of the ones I've I've heard from inside, they were the metal brake lines that attach to the lower firewall on the driver's side, and two silver A/C lines (one big, one small) that were creating high-pitched creaking within an aluminum holder on the passenger's side, and the smaller line was lightly tapping against the side of the chasis. It's possible since those brake lines could move a bit as pressure increases when the brake pedal is depressed, that you might have a loose brake line bracket whose plastic retention tab is snapping/popping in and out of its hole in the firewall, which could explain why it's happening when manipulating the brake pedal.
If Nissan confirmed the noise is normal, maybe return and try out a few other cars to see if the noise is present. If not, show the service manager the differences between vehicles and say you can't live with the noise. You can also say other 2021 MO owners aren't hearing that noise. I tried to make my 2021 click when using the brake and placing the shifter in different positions, but all is quiet. BTW, what trim is your 2021? Knowing that could make a difference regarding certain electronics your MO may or may not have to help more experienced members diagnose your trouble. Mine is an SL AWD.