Is it allowed to let the engine of an aircraft idle without a pilot in the plane. (For both helicopters and aeroplanes)
You won't see it done in the fixed wing world unless the aircraft is tied down or otherwise securely restrained (like when you tie off the tail to something when hand starting your no-starter taildragger; some pilots just use chocks or parking brakes to hand bomb their airplane, but it's a terrible idea).

However, it's common in the helicopter world especially in bush operations.  With the collective and cyclic friction locks tightened down and the engine in ground idle, it can't really go anywhere and a pilot who lands in a remote area without assistance to hook up a sling load or lug something on board will often do it without shutting down.