"Degrees of freedom" is the number of values (or variables) that can vary or change while still keeping the value of some quantity fixed.
For example, if you had the following four values, 75, 85, 65, and 95, the average would be 80. This is because 75+85+65+95 = 320, so when we divide by 4, we get: 320/4 = 80. Notice that the final average would remain 80 as long as the sum of the four values remained 320.
How many of these four values could you randomly change yet still guarantee a sum of 320? The answer is three of the four can change randomly because no matter what three initial values you select (say for example you randomly chose -10, 0, and 5), you can always arrive at a sum of 320 as long as you choose the right 4th value (in this case, -10 + 0 + 5 = -5, so I am forced to choose 325 as my last value to get a sum of 320). Notice, there was no freedom of choice on the 4th value. I had to make it 325, or my sum would not be 320. Thus, I can say that the degrees of freedom here is 3 because three values can change randomly while ensuring a sum of 320 (which gives an average of 80).
Hopefully, that helps. Let me know if you have a follow up question,