How can I freestyle render outlines but remove the object itself?
It looks as though you want to make the walls transparent to the floor, but not to themselves. (They're occluding their own back edges)
For maximum flexibility, you can set Cycles to render a separate Freestyle-only pass on transparent film ..

EDIT: 2.91 .. I think the filter selection is now negative: what's required is to uncheck all filter options, with Freestyle switched on.

.. link your walls and floors to separate Collections ... here, named 'Solid' and 'Transparent'.

Create a View Layer for each Collection. Deactivate unwanted collections in the corresponding layers as shown above. Each layer gets its own Freestyle Line Sets, which can be set to pick up Visible, Freestyle-Marked edges. Then you don't have to worry about transparency in the Line Sets themselves, because you're using the Compositor to overlay them:

This will increase rendering time a little (is this for still images?) but you can set the samples down in Cycles quite a way, 32 seems to give adequate anti-aliasing on the lines.