Add `getPk` method for Model.