The usual pattern is to have a cell along the lines of Cell<ImmutableMap<Int,Cell>>
, which is defined a hold of the merge of two streams: one for adding items, and one for removing them. When adding items, you have to allocate a unique number. When removing them, your logic has to remember the number that was allocated.
Basically in real functional programming, there is no such thing as a reference to an object. Because of that, you have to use unique keys - usually integers - to reference things. You might find it useful to use Supply - which is in the book and will be somewhere in the examples directory - to allocate unique numbers. Alternatively, you can just get the highest key in the ImmutableMap data structure and add 1 to it.
Another way to view this is that in functional programming, data structures (the word "objects" isn't really used) do not have any identity other than their value. If they contain functions, then they don't have any identity at all, because functions are opaque: there is no way to ask if one function equals another. Cells and streams are the same. There is no equality operation for them. Java will let you compare the references to them, but in FRP/FP that is a totally invalid thing to do.