The answer
If you read carefully, Holy Book of Exodus 20:4,5 and Holy Book of Leviticus 26:1,2 together you will notice that God did not stop at saying "You shall not make idols for yourselves; neither a carved image" but continued on saying, "do not bow down to them nor serve them." Later on we read in Holy Book of Exodus 25:17-20 that God gave Moses intricate details on how to build the Mercy Seat and to put on it two carved images of cherubs made of gold. Again when building the Tabernacle, God instructed Moses saying, "Moreover you shall make the tabernacle with ten curtains of fine woven linen and blue, purple, and scarlet thread; with artistic designs of cherubim you shall weave them" (Exodus 26:1). God was not against the images but against idolatry.Also we do not worship the icons referred to in your question. We venerate them as they are consecrated with the Holy Oil (Myron).
Answered by His Eminence Metropolitan Youssef (opens in a new tab)