Caste system in India or in Hinduism has became a point of Criticism for Hindus but without knowing about the caste system, we can't give a proper conclusion.Dalits are leaving Hinduism because of discrimination and not being equally treated. They are joining other religions like Buddhism, Christianity, Jainism and Islam. Caste system is not just at present, its been there for centuries. That's why other religions got an opportunity to flourish as they are offering equality among all, and universal brotherhood.
Caste System In Vedas
Vedas are considered the most pious texts for Hindus and in the RigVeda we found the mention of caste system in Rigveda Samhita Mondal 10, Sukta 90, Richa 12, there is a verse about Varna system.
ब्राह्मणोऽस्य मुखमासीद्बाहू राजन्यः कृतः ।
ऊरू तदस्य यद्वैश्यः पद्भ्यां शूद्रोऽजायतः ॥
Brāhmano-syā mukha-masidbahu rajanyā kratah
Uru tadasya yadvaishya: Padb-hyana shudro-jayā
It says the origin of the four Varnas, the face of that Supreme is Brahman, the arm became due to the Kshatriyas his thighs became Vaishyas and the feet produced Shudras.There is nothing discriminatory in Vedas this verse is just a metaphor for the varna system or the work classification. It is obvious that a person loves his feet as much as he does to his arms. Even Scholars including B.R Ambedkar has also agreed that there was no casteism in the post Vedic society.
Caste System In Bhagavad Gita
Bhagavad Gita is one of the most sacred books in Hinduism and it is also the most rising book in Hinduism, In Bhagavad Gita's chapter 4 verse 13, Krishna has talked about Varna system.
चातुर्वर्ण्यं मया सृष्टं गुणकर्मविभागश: |
तस्य कर्तारमपि मां विद्ध्यकर्तारमव्ययम् ||
chātur-varṇyaṁ mayā sṛiṣhṭaṁ guṇa-karma-vibhāgaśhaḥ
tasya kartāram api māṁ viddhyakartāram avyayam
In this verse Krishna says the four varnas are created by me based on the differentiation of quality and action, even though I am its creator : know me as the non-doer and indestructible.
There Is an another verse that gives more clarification about Varna system in Bhagavad Gita's chapter 5 verse 18 Krishna talks about true divine wisdom.
विद्याविनयसम्पन्ने ब्राह्मणे गवि हस्तिनि |
शुनि चैव श्वपाके च पण्डिता: समदर्शिन: ||
vidyā-vinaya-sampanne brāhmaṇe gavi hastini
śhuni chaiva śhva-pāke cha paṇḍitāḥ sama-darśhinaḥ
In this verse Krishna says "the truly learned with the eyes of divine knowledge, see with equal vision a Brahman, a Cow, an Elephant, a dog and a dog-eater."
These verses totally abrades the caste system and shows us that the varna system just was the classification of duties, like today's scientist and teacher would be Brahman whether they come from any family these verses proves that there was no castism, it was a varna system, not a caste system, unfortunately it gradually turned into a caste system.
Caste System In Manusmriti
Manusmriti is the most controversial book in Hinduism because it has some strict rules about caste system, It prohibits moving between casts, if you are born in the lower caste you will be listed there forever. No matter how literate you are. You are fixed by birth.
Manusmriti has a verse about caste system in chapter 1 verse 31.
लोकानां तु विवृद्ध्यर्थं मुखबाहूरूपादतः ।
ब्राह्मणं क्षत्रियं वैश्यं शूद्रं च निरवर्तयत् ॥
lokānāṃ tu vivṛddhyarthaṃ mukha-bāhū-rupādataḥ
brāhmaṇaṃ kṣatriyaṃ vaiśyaṃ śūdraṃ ca niravartayat
The manusmriti is an ancient constitution of Hindus written by Rishi Muni, Smrities are the legal texts of Hinduism like today's constitution. Hindus not only have Manusmriti but also has smrities like Narada Smriti, Yajnavalkya Smriti, Parashara Smriti, Brahaspati Smriti, Katyayan Smriti and Devala Smriti. Every Smriti has different-different rules for the society to function and some has quite different approach and contradiction.Hindus were not only following Manusmriti but also followed other Smrities. In the Gupta Empire they were following three differnt smrities, like Narada Smriti, Brihaspati Smriti and Manusmriti as well.And if there is something that is not working for us in the present time, it doesn't mean that it was created with bad intention, these all Smrities were not god-given things, they were created by the wise people of their time.If there are any drawbacks in our constitution, then we amend the constitution we do not blame the creator of the constitution.As of January 2020 there, have been 104 amendments of the Indian Constitution since it was enacted in 1950. Should we condemn Gandhiji or Ambedkar ji? It's not logical, They did what was good at that time the same thing goes with the manusmriti. I never found out anything bad in Hinduism there is nothing discriminatory.Since ancient times, many Rishies like Ramanujacharya Shankaracharya rejected the caste system and many movements made lots of efforts to abolish the caste system like Bhakti Movement, ISKCON. There are many organizations which still exist in India engaged in abolishing the caste system.
Another reason why Manusmriti has these strict rules about Caste System is that Hinduism do not welcome meat eater inside temples still these days people prohibit themselves going inside temple if they consumed non veg, surely these rules were so strong on those days and eating meat and drinking alcohol is still considered a devil quality for a humans in Hinduism.
I known nowadays lots of people go inside the temple still they consumed non veg but certain things happened during a long period and it is not good but the this was not designed to be like that, time has changed and now every caste is involved is everything it's time to make it better and treat everyone equally.