traveler who is planning on staying in hostel dorms
Make a different plan. Your question assumes that the hosteler simply will not change accommodation plans and will perform the self-isolation in a hostel. Not gonna happen.
The hosteler must find out what the government considers to be a viable self-quarantine plan. And then make that plan, whatever it takes. Get to a different space where self-isolation is actually viable. Upgrade to a hotel room, find a friend willing to accommodate, secure food and entertainment supply etc. per what the government considers reasonable.
And they better be able to answer questions about that plan if immigration asks.
If the hosteler is unable to change plans, then it's time to either self-arrange to leave the country... or contact the embassy and ask for assistance in repatriation... or avail local government assistance. That rubs wrong a visitor's agreement not to rely on government services, but I'm sure the government would prefer you ask for help in this case.
If the hosteler is unwilling to change plans, that misses the entire point of immigration, which is that you agree to be a lawful citizen and a boon to the nation (e.g. bringing tourist activity and funds). Flouting the law deserves the swift boot.
As Dave Smylie reports, that is exactly what is happening in New Zealand to a pair, and to a single. In one case, the fundamental flaw was a 2 week visit (that would be spent entirely in self-isolation, then fly home). There were no travel adjustments, change to an appropriate facility (e.g. hotel with viable food service, microwave etc.), no stocking on food or entertainment. The only thing that made sense was that the tourist intended to flout the restrictions. So the boot they got!
Worse, here's the mechanism: They are in "jail", immigration detention, where they will sit out the 14 day isolation. After that, they'll be given a deportation order, and freed on their own recognizance to arrange transport, gather their things and self-deport. I call that "giving them enough rope to hang themselves" :) Of course Immigration is watching, and their conduct will decide whether they ever again visit NZ, or countries that NZ interchanges data with.