Rename pkgid and PkgId to crateid and CrateId

Issue #11048