The problem is cooling air. Another issue "MAY BE" head room in the gen compartment. The portable,depending on what you choose may be too tall to fit. You need to get the hot air that comes out of the end of the generator (Honda) out of the compartment. It will loop around and go right back into the inlet air opening and overheat it if you don't deal with the exhaust and hot air. Do that then all you have to do is figure out how to get fuel into the generator tank. FYI Honda is the only one with a fuel pump. It can surely be done but it will take some engineering.
I have a Honda EU 1000i in a sound deadening box that carry with us in the back of the toad to charge batteries when the solar won't keep up when we boondock. It is almost silent. It weights about 60# and I just set it behind the coach and plug it into the shore power. I have a 3 gallon tank hooked to it and it will last many days when the weather is rotten. It has over 1600 hours on it and all I have done to it is oil changes.