They have come out of slavery to the mountain of God. The Lord is going to teach them more things they need to know. He is going to reinforce Moses’ leadership, and give them good laws to live by. He is also going to teach them about holiness – that God is higher and separate from them – He is not there to serve them, but they are to serve Him. He is holy.
Pharaoh didn’t care about the slaves at all – and he was totally separate from them. So the Israelites understand separation. What they don’t understand is that the Lord LOVES them, cares for them, ransomed them – and is also holy. They have not had a ruler they could fear AND love. The commands of God are not a burden – that we try to not do every time God’s back is turned (it never is!). We love His rules because they lead us closer to Him (it’s not about the rules, it is about loving Him). There is a “rule” that I have to talk to my friends or wife to have a relationship – this rule is not a burden, but part of the relationship.
The people don’t understand all of this yet, and sometimes I think we still don’t understand. Either we fear God and don’t want to keep His commands, or we think it is all about the rules. God shows us that He is holy, but is still close to us, and loves us. When I love and honor Him, when I see all He has done for me, when I understand His rules are for my benefit – that puts me in right relationship with Him, and I WANT to follow and obey.