Error Code 1068 is for Multiple Primary Keys (not allowed)
Error Code 1075 is for Incorrect Table Definition (auto_increment fields must be defined as a key). It looks like enrollmentindex is an auto_increment field, so it will need to be included in your composite primary key.
I would suggest creating a separate UNIQUE index on username,shortname,role
, if that's something you want to force