RC is a GC algorithm, so it is already there.
In Rust you do so via borrow checker or explicit Rc/Weak wrappers. In Swift you do that via additional weak annotations (strong being the implicit default).
It doesn't care about ownership either. Apart from some Swift specific optimizations iiuc.
Full GC I mentioned is more of mark and sweep variety.
See Reference counting. Note lack of malloc/free.
See this excellent comment: https://news.ycombinator.com/item?id=32277088
You can start here,
https://www.udemy.com/course/essentials-of-garbage-collector...