I had the same issue - only PK were migrated by AWS DMS.
Secondary indexes, Auto-increment counters, users and grants (everything which is not part of the data) had to be migrated separately.
The solution:
Dump db structure from the source RDS:
mysqldump -u <username> -P <port> -h <host_source> --no-data -p --all-databases > schemas.sql
Import the structure on the target RDS:
mysql -u <username> -P <port> -h <host_target> -p < schemas.sql
Specify in the Data Migration task "Do nothing" with tables on the target
Note:
For migrating large databases it is better to switch to bigger RDS instance type. Experience showed the migration will be stable when all RDS instances are in the same region (AZ) and have the same/similar instance type i.e. source, target and replica instances.
And the most important is to switch RDS Storage Provisioned IOPS with some custom high values (depends on the db data size).
Reference to the doc
Missing Foreign Keys and Secondary Indexes
AWS DMS creates tables, primary keys, and in some cases unique indexes, but it doesn't create any other objects that are not required to efficiently migrate the data from the source. For example, it doesn't create secondary indexes, non-primary key constraints, or data defaults.
To migrate secondary objects from your database, use the database's native tools if you are migrating to the same database engine as your source database. Use the Schema Conversion Tool if you are migrating to a different database engine than that used by your source database to migrate secondary objects.
PS It is not efficient to import data into tables with indexes, the trade off depends on each case.