That is not true. The fact that by eating of that tree Adam would die death. And that warning was given to Adam before God made woman on the sixth day. (Genesis 2:26-27.)
Eve was not created on the 6th day. Eve was not created from dust. Eve was taken out of Adam.
The Garden of Eden was not planted on the 6th day. The Garden was planted after the Sabbath Day, which was a Millennium. God rested for a Lord's Day. 2 Peter 3:8.
There was no death, and Satan could not rebel until after the Sabbath Day of the Lord. Many generations of humans and animal life happened in that Millennium. There were no wild plants, nor any new plants for a literal 1,000 years. There will be another Sabbath Day of the Lord after the Second Coming of Jesus as Prince. Conditions will be restored once again to like that time on earth. No more sin, and death and decay because of sin. Satan will again be bound to not interfere in human life on earth.
So the tree of life and the tree of the knowledge of good and evil were not even planted until after the first 1,000 years. Only then was Adam placed in the Garden, along with those two newly planted trees. The Garden of Eden was not planted on the 6th day. When God rested it had been less than 24 hours. Humans barely had time to meet each other. God rested so many generations could establish themselves on earth. Except plants. No new trees or plants for 1,000 years.
That is what these verses declare:
"Thus the heavens and the earth were finished, and all the host of them. And on the seventh day God ended his work which he had made; and he rested on the seventh day from all his work which he had made. And God blessed the seventh day, and sanctified it: because that in it he had rested from all his work which God created and made.
These are the generations of the heavens and of the earth when they were created, in the day that the Lord God made the earth and the heavens,"
Generations are plural, and day is singular. Time elapsed more than an earthly 24 hours. The Day of the Lord was 1,000 years to those living on earth. God let creation do what creation was designed to do for 1,000 years.
Then God planted a Garden, and history changed from that point on. No one could have eaten from the tree, thus no one knew good nor evil. No one knew what death was because Adam's disobedience caused the first death ever. Paul taught that in 1 Corinthians 15:21-22
"For since
by man came death, by man came also the resurrection of the dead. For as
in Adam all die, even so in Christ shall all be made alive."
Romans 5:12-14
"Wherefore, as by one man sin entered into the world, and
death by sin; and so death passed upon all men, for that all have sinned: (For until the law sin was in the world: but sin is not imputed when there is no law. Nevertheless
death reigned from Adam to Moses, even over them that had not sinned after the similitude of Adam's transgression, who is the figure of him that was to come."
It was only Adam's disobedience that caused Adam to die. Then God cursed the ground, and now plants would die.
"and hast eaten of the tree, of which I commanded thee, saying, Thou shalt not eat of it:
cursed is the ground for thy sake; in sorrow shalt thou eat of it all the days of thy life; Thorns also and thistles shall it bring forth to thee; and thou shalt eat the herb of the field;"
That is when seeds became wild plants growing up called weeds. That is when plants died and had to be planted again every season. Before that no human ever tilled the ground. Genesis 2:5. The verse does not mean there were no humans around. It means no humans tilled the earth until the ground was cursed because of Adam's punishment.