How to save a csv file as pytorch Dataset object

I have a dataset for text classification which is in the format of a CSV file.

For training a PyTorch model I came to know that I should change the CSV format data into Pytorch Dataset format. How can I convert my CSV file to PyTorch Dataset format and save it in the local file?