Take a look at the l10n_uk module. This module imports a CSV file to populate UK Counties.
https://github.com/odoo/odoo/tree/10.0/addons/l10n_uk
You can see in the __manifest__ file of the module the direction to import the file:
'data': [
'data/res.country.state.csv',
],
Also at https://github.com/odoo/odoo/blob/10.0/addons/l10n_uk/__manifest__.py#L26
The CSV file looks like this:
"id","country_id:id","code","name"
"state_uk_1","base.uk","A1","Aberdeenshire"
"state_uk_2","base.uk","A5","Angus"
"state_uk_3","base.uk","A7","Argyll"
"state_uk_4","base.uk","A9","Avon"
"state_uk_5","base.uk","B1","Ayrshire"
"state_uk_6","base.uk","B3","Banffshire"
"state_uk_7","base.uk","B5","Bedfordshire"
"state_uk_8","base.uk","B7","Berkshire"
"state_uk_9","base.uk","B9","Berwickshire"
"state_uk_10","base.uk","C1","Buckinghamshire"
"state_uk_11","base.uk","C3","Caithness"
Also at https://github.com/odoo/odoo/blob/10.0/addons/l10n_uk/data/res.country.state.csv
Which imports these records into Odoo:
Also, see:
https://www.odoo.com/documentation/10.0/reference/data.html#csv-data-files
Save CSV to Database: http://learnopenerp.blogspot.com/2019/10/how-to-use-self-env-cr-copy-from-to-save-data-in-database.html