Why Git Submodules?

Git addresses this issue using submodulesSubmodules allow you to keep a Gitrepository as a subdirectory of another Git repository. This lets you clone another repository into your project and keep your commits separate.

https://git-scm.com/book/en/v2/Git-Tools-Submodules