Tithes pre-dated the Law.
Genesis 14:18-20. And Melchizedek king of Salem brought out bread and wine. (He was priest of God Most High.) And he blessed him and said, “Blessed be Abram by God Most High, Possessor of heaven and earth; and blessed be God Most High, who has delivered your enemies into your hand!
And Abram gave him a tenth of everything.
Genesis 28:20-22 Then Jacob made a vow, saying, If God will be with me and will keep me in this way that I go, and will give me bread to eat and clothing to wear, so that I come again to my father's house in peace, then the Lord shall be my God, and this stone, which I have set up for a pillar, shall be God's house. And of all that you give me I will give a full tenth to you.