Yes, Gradle does this kind of stuff very well. Generally, I’d say that if you want to have all libraries published at once (usually with the same version numbers), use multi-project build. If you want to version and release the libraries independently of one another (release v1.1 of B and A, but keep C at 1.0 and don’t publish it), then a composite build might be better.
Composite builds are typically useful when each build is a separate Git repo, but those repos depend on each other. Multi-project builds are the more traditional “monorepo”, where a single repo has multiple independant but interlinked sub-projects.