queue: implements Put and Get methods