Don't understand what you exactly want to accomplish with toggling the volume, but you might have a look at Settings->Audio and activate push-to-mute for the sound source you mean. This way you activate a feature that while you press and hold some hotkey down, the corresponding source is muted. It can be used for example for muting your mic while you cough. In this dialog you activate the feature, and he actual hotkey is set in Settings->Hotkeys.
If you just want to avoid that the regular audio drowns your voice, do something different. Open the Filters section of your Desktop Audio source in OBS and add a "Compressor" Filter. In the options of that filter, at Sidechain/Ducking Source add the source of your Mic. This way, the filter's efficiency is controlled by your mic. With the Ratio and "Output Gain" settings you can regulate how much Desktop Audio is reduced.