The words cast, caste sound the same but have different meanings and spellings. Why do cast, caste sound the same even though they are completely different words?
The answer is simple: cast, caste are homophones of the English language.
To draw (lots).
To throw (something, especially something light): The angler cast the line.
To throw with force; hurl: waves that cast driftwood far up on the shore. See Synonyms at throw.
To shed; molt.
Any of the hereditary, endogamous social classes or subclasses of traditional Hindu society, stratified according to Hindu ritual purity, especially the Brahman, Kshatriya, Vaisya, and Sudra castes.
A social class separated from others by distinctions of hereditary rank, profession, or wealth.
A social system or the principle of grading society based on castes.
The social position or status conferred by a system based on castes: lose caste by doing work beneath one's station.
Definitions from The American Heritage® Dictionary of the English Language, 4th Edition and Wordnik.
Homophones (literally "same sound") are usually defined as words that share the same pronunciation, regardless of how they are spelled.