It’s not part of the relative clause if it’s genitive. It’s using its genitive effect on the whole relative clause that follows. But you can make sentences that work either way.
At the end of the day, this is a “looking under the hood” type discussion. As long as you know when you can use が and の you don’t need to know how linguists break the sentences up.