These are the men whom the Lord commanded to divide the inheritance for the people of Israel in the land of Canaan.
Eventually the Promised Land became Israel's possession. They transitioned from being a people wandering the desert to becoming a nation settled in cities and farms and villages in Canaan, a place God gave them. As God appoints tribal leaders whose job it is to divide holdings of land by family, the Israelites under Joshua are being prepared to fight off Canaanites and receive this gift from God.
This passage is a bit administrative detail, but the plan to divide the territory needed to be in place before any battles could be waged. The order in which God prepared Israel was smart planning. God moved the people to prepare them to receive this inheritance that He had promised Abram so many generations earlier.
Sometimes people need to be ready to receive God's promises. The tribal leaders needed to be in place BEFORE the battle for Canaan could be won. The plan for what to do with what God would give needed to happen BEFORE the armies could march, the battles could be won, and new homes come to God's people.