creating new resource in modal window