Error Code DirectX 0X887A0005 Call of duty Black Ops 6

Downgrade your Nvidia drivers to 561.09 and it should stop crashing.

The crashing most likely due to the Memory Leak.

also reset the settings if the PC is overclocked.

Also try reducing the settings from the NVIDIA Control Panel