CLN: csv refactor
ENH: add (undocumented) legacy kwd to df.to_csv, just in case
CLN: refactor of csv
     moved code to fmt/CSVFormatter
     moved block and index formatting code to internals/index
TST: fail early on duplicate columns