How to replace a Volume Profile during runtime?

Is it possible to replace a volume profile during gameplay in URP? I know that we can override the values of PP but what I want is to create separate volume profiles and switch between them on specific event during runtime? The question might be awkward but I am newbie. Thank you.

You can reference a profile and a volume as below

public Volume volume;
public VolumeProfile profile;

Create a PP profile and save in your assets as a prefab, assign it to profile, assign your gameobject with a PP Volume to volume

You can switch the profile whenever you want with

volume.profile = profile;

You will also need to reference

using UnityEngine.Rendering;