You have asked 3 questions.
What is the need for the Puranas?
Veda-Vyasa wrote the Puranas after Rishi Narada scolded him and advised him to write texts glorifying the Lord.
Narada said in reply: You have not adequately described the unsullied
glory of the Supreme Lord. I consider as imperfect all those
philosophies which fail to please the Lord because of their lack of
devotional exuberance, which can alone give full satisfaction to Him.
You have not expounded the greatness of Vasudeva with that
exhaustiveness with which you have treated the Vedic rites and the
four-fold end of human life, consisting of Dharma, Artha, Kama and
Moksha (Virtue, Wealth, Desire and Liberation). Works of pure literary
artistry, that nowhere describe the sanctifying glory of the Lord are
eschewed by the Paramhamsas who are ever accustomed to sport in the
Manasa lake of Satchidananda alone. They discard such compositions,
considering them only as dirty mud puddles fit for the bath of the
crows of sensual worldlings. Literary compositions, which are
characterised by the presence of words indicating divine attributes
and glory, destroy the sins and evil tendencies of people even if
there are mistakes in every one of their lines. Holy men hear the
exposition of such texts and themselves expound and sing them.
Srimad Bhagavata Purana I.5.8-11
What is the need for the Upanishads?
The current arrangement of the Vedas grouped into Samhitas, Brahmanas, Aranyakas and Upanishads is due to Vyasa. Originally there was only one Veda.
He re-edited the Veda, which was a single unit originally, by dividing it
into four, so that the sanctifying institution of the Vedic Yajna,
performed by four officiating priests, may not disappear from the
human society. He then revived the Veda by editing it into four
books, the Rik, Sama, Yajus and Atharva, and he also brought into
existence the Itihasa and Puranas - the sacred traditional histories
and the ancient sacred lore known as the fifth Veda. Had it not been
for this work of the Great Rishi, man with his deteriorating
intellectual capacity, would have forgotten all this massive sacred
Srimad Bhagavata Purana I.4.19-20
How could there be errors in the Vedic literature?
There are errors in the Vedic literature. This is acknowledged in the Puranas.
Rishi Narada in fact scolded Vyasa for saving the karma kanda of the Vedas which is bad for humanity.
It has indeed been a great transgression on your part to have declared
the desire-motivated ritualistic rites of the Vedas as Dharma to the
materially- minded and sense-bound man. For, established on the
strength of your declaration, in the faith that Vedic ritualism is
Dharma, they will not heed to their deprecation in other Sastras or
even in your own works.
Srimad Bhagavata Purana I.5.15
Swami Vivekananda also considered the Vedas as full of errors. He also tells us how to view the Vedas.
There was a time when the Vedas themselves were considered eternal in
the sense in which the divine truths contained therein were changeless
and permanent and were only revealed to man. At a subsequent time, it
appears that the utterances of the Vedic hymns with the knowledge of
its meaning was important; and it was held that the hymns themselves
must have had a divine origin. At a still later period, the meaning of
the hymns showed that many of them could not be of divine origin,
because they inculcated upon mankind performance of various unholy
acts, such as torturing animals; and we can find many ridiculous
stories in the Vedas. The correct meaning of the statement "The Vedas
are beginningless and eternal" is that the law or truth revealed by
them to man is permanent and changeless. Logic, geometry, chemistry,
etc., reveal also a law or truth which is permanent and changeless and
in that sense they are also beginningless and eternal. But no truth or
law is absent from the Vedas, and I ask any one of you to point out to
me any truth which is not treated of in them.
The Complete Works of Swami Vivekananda, Vol.5: With the Swami Vivekananda at Madura, pp.205-206
Adi Sankaracharya has an interesting thing to say about the true meaning of the claim that Vedas are infallible.
The appeal to the infallibility of the Vedic injunction is
misconceived. The infallibility in question refers only to the unseen
forces or apurva, and is admissible only in regards to matters not
confined to the sphere of direct perceptions, etc ... Even a hundred
statements of sruti to the effect that fire is cold and non-luminous
won't prove valid. If it does make such a statement, its import will
have to be interpreted differently. Otherwise, validity won't attach
to it. Nothing in conflict with the means of valid cognition or with
its own statements may be imputed to sruti.
REF: Srimad Bhagavad Gita Bhasya of Sri Sankaracarya translation by Dr. A. G. Krishna Warrier, p. 629.