@pranavgupta you could try to use R to write the CSV file and see if there is a different outcome.
CSV files are not ideal when transferring data but I do understand why they are still being used.
Sometimes I used even more excotic characters as separators like the “flattened turtle”
¤
ASCII 164. And you definitely should check for some hidden line breaks in the original data.