They were built in administrative offices (including the Treasury Ministry, or "Okurasho" in Japanese) to keep rice and other articles from different regions, which were paid as a tax during the Nara period.
奈良時代に各地から上納された米穀や物品などを保管するため、大蔵省をはじめとする役所に設けられたものであった。