I’ve found that it’s possible to store keys in strings.xml and refer to them from preferences.xml just like all other values android:key="@string/preference_enable".
In code you can refer to key by typing getString(R.string.preference_enable)
You can mark the string to not be translated using a <xliff:g> tag. See Localization Checklist
<string name="preference_enable"><xliff:g id="preference_key">enable</xliff:g></string>