Because different objects can have the same hash. For example, if you had Int128, then you cannot give each of them unique hash. Because of that Dictionary and other types using Hashable first quickly check if there is a matching hash, and then make sure you have the same object using ==
.
tl;dr
if a == b, then a.hashValue == b.hashValue, but if a.hashValue == b.hashValue, then a may or may not equal b