`where.not` adds `references` for `includes`.

Closes #14406.

Conflicts:
	activerecord/CHANGELOG.md