If an attacker wanted to hand me bad code, couldn’t they also hand me a bad signature/certificate/key?
This is what multi-party key signing is for. Now, multiple people verify code, and also verify build artifacts. Rather than trusting an individual, you trust a process during which developer's continuously verify each other.
The other thing to note is that the builder is not always the distributor. For example many Linux distro's have mirrors setup, where they share their built artifacts to other institutions and hosters, who then redistribute code.
Even for a single party, key signing has value because it ensures that everything after the original creation of the artifacts is not compromised, as long as the key distribution system is different than the distribution system of the artifacts.
But for a solo dev on Github, yes. Signing doesn't really do anything, since the developer and the distribution chain are close enough that it's highly likely the key would be compromised along with the source.

Step 1 is communication.
Talk to your english teacher. Explain to them, why Google Docs, the way they track history and changes, is not a preferred option for you, due to ethical or privacy considerations.
Explain to them your selected technical alternatives for tracking changes. A few alternatives are (many commenters already covered):
Secondly, you need to remember that what your english teacher wants is not "document history", but instead seeing your process (maybe to prove you didn't chatgpt it, in which case, writing it on paper also might prove that). If none of those technical alternatives are viable solutions for them, another alternative is to simply submit documents that encapsulate each stage of the process. For example, a common pattern that my teachers and professors would do for writing assignments is:
The above setup is nice, because it is not tied to any particular software, and can even be executed on paper. This would mean that future students, similar to you, going through the same class, could write essays with their preferred writing software, instead of only with google docs or whatever solution you get the teacher to learn how to work with (assuming they are nontechnical and teaching the teacher is difficult.
I only started seeing it done like this in college classes. High school classes only sometimes required an outline, and never required an annotated bibliography. It also is more work then just writing an essay from sources.
But the two big benefits of this setup are:
Good Luck!