What you may want to look into is adding a bridge interface and then adding the vlan interface you want to the bridge, then adding those three ports to the bridge interface, this would allow you to carry the vlan traffic on say eth4 over to eth2-3. Keep in mind that eth0 and eth1 can NOT be added to the bridge interface.
I tested this myself and it worked fine, but then decided to switch and try out the edgerouter-x device as all the ports are actually hardware switched interfaces vs only 3 as in the ER5-POE and better applied to the application I needed, as well as being a cheaper device.
Ubiquiti carries a wide range of devices, all of which are geared toward specific use cases.