This blog post goes through the documented TechNet process for migrating legacy public folders to Exchange 2013/2016, expanded with real world guidance gained from field support.
Part 0: Verify public folder replication
Part 1: Download the migration scripts
Part 2: Prepare the Exchange 2010 server and public folders for the migration
Part 3: Generate the CSV files
Part 4: Create the public folder mailboxes in Exchange 2016
Part 5: Start the public folder migration
Part 6: Complete the public folder migration (downtime required)
Part 7: Finalize the public folder migration (downtime required)
Part 8: Test and unlock the public folders
Get full details and notes on the Exchange Team Blog.