I am not sure how to specify the branch with the git+https
protocol (in a way that is supported by the protocol).
However using https with a commit specific download url works as a workaround:
zig fetch --save https://github.com/epizzella/RTOS/archive/9d4801c309f5142848f124092034dd59a270e2f5.zip