There's some documentation about contributing to CTS here:
https://source.android.com/docs/compatibility/cts#components
https://source.android.com/docs/setup/contribute/submit-patches
It's encouraged to contribute, but for the final certification it's not allowed to have local CTS patches as it needs to be run with the official binaries.