Escaping while writing to csv