Declaring a primary key results in the automatic creation of a unique constraint on the primary key. To enforce the constraint, the dbms uses an index.
So its implied already.
Foreign keys, OTOH, do not automatically get indexed but can often benefit by the addition of a non-unique index - depending on access patterns.
If I am wrong, somebody please correct my understanding.