QGIS Value Relation Widget saves not the KEY COLUMN values but the …

Even after saving the project to the Geopackage, restarting QGIS, and reopening the project, nothing changes. Please advise. PS I’m somewhat surprised that even if the data type of a field is defined as an integer, the Value Relation widget can store a text string in it, for example, “village” instead of “1”, “town” instead of “2” etc.  

https://gis.stackexchange.com/questions/474854/qgis-value-relation-widget-saves-not-the-key-column-values-but-the-value-column