Scene volume does not reduce when master volume is lowered

I have set a volume slider which is connected to the master volume, but it does not reduce the volume even if the slider is reduced or increased(even though in the audio mixer it shows master volume being reduced when the slider is moved) The code for slider is given below:

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.Audio;

public class OptionsMenu : MonoBehaviour
{
public AudioMixer mixer;

public void SetLevel(float sliderValue)
     {
         mixer.SetFloat("MasterVolume", Mathf.Log10(sliderValue) * 20);
     }
}

I have various scenes in the game, but I want this controller to reduce volume for all the scenes(it is the main volume controller in options menu). However it doesn’t even reduce volume for the MainMenu scene which contains the options Menu. What should I do to resolve this?
(please give me a beginner friendly solution)

Have you set the Output property on your AudioSources to use your mixer?

I am not using an audio listener in the game(or at least thats what I hope), however I have made an AudioManager which has all the audio clips stored(it is like the audio source function). So how do you suggest I set the Output property from the AudioManager script to use the mixer?
The code for my audio manager script is below:

using UnityEngine.Audio;
using System;
using UnityEngine;

public class AudioManager : MonoBehaviour
{

    public Sound[] sounds;

    // Start is called before the first frame update
    void Awake()
    {
        foreach (Sound s in sounds)
        {
            s.source = gameObject.AddComponent<AudioSource>();
            s.source.clip = s.clip;

            s.source.volume = s.volume;
            s.source.pitch = s.pitch;
            s.source.loop = s.loop;
        }
    }

    void Start()
    {
        //Play("InGame");
    }

    public void Play(string name)
    {
        Sound s = Array.Find(sounds, sound => sound.name == name);
        if (s == null)
        {
            Debug.LogWarning("Sound: " + name + "not found!");
            return;
        }
     
        s.source.Play();
     

     
    }

    public void Pause(string name)
    {
        Sound s = Array.Find(sounds, sound => sound.name == name);
        if (s == null)
        {
            Debug.LogWarning("Sound: " + name + "not found!");
            return;
        }

        s.source.Pause();
    }

    public void Resume(string name)
    {
        Sound s = Array.Find(sounds, sound => sound.name == name);
        if (s == null)
        {
            Debug.LogWarning("Sound: " + name + "not found!");
            return;
        }

        s.source.UnPause();
    }

}

So what do you suggest?
CORRECTION: I have added the audio listener to my Main Camera, and it was a really dumb thing to forget about it. In the Manual it only tells you that you can use the Audio Source to link it with Audio mixer, however there is no example given on how to do so, could you explain please?

UPDATE: I got it, all you have to do is make the audio mixer as a public class and refer to it in the inspector, then you have to set the audio source to the audio mixer, both the codes are below:

before the awake command(wherever you have marked your public and private values) add this:
public AudioMixerGroup audioMixer;

And then in the awake command add:
s.source.outputAudioMixerGroup = audioMixer;

Hope this helps you whoever is reading this in the future, Good Bye!

Like I said, you need to set the Output property of the AudioSource to your mixer. So in your AudioManager add a field for your mixer:

public AudioMixerGroup mixerGroup;

Assign your mixer asset to that field in the editor, then add to your Awake:

        foreach (Sound s in sounds)
        {
            s.source = gameObject.AddComponent<AudioSource>();
            s.outputAudioMixerGroup = mixerGroup;
            // the rest...
        }

This might be a stupid idea but I usually connect my MasterVolume slider to my AudioListener volume. That field is static and can be accessed from anywhere and did the job for me so far.
Is that a good idea? If not, could anybody explain to me why?