Inclusive cross sections for J/ψ production in proton-proton collisions were calculated in the kt-factorization approach for the RHIC energy. Several mechanisms were considered, including direct color-singlet mechanism, radiative decays of χc mesons, decays of ψ ′ , open-charm associated production of J/ψ as well as weak decays of B mesons. Different unintegrated gluon distributions from the literature were used. We find that radiative χc decays and direct color-singlet contributions constitute the dominant mechanism of J/ψ production. These process cannot be consistently treated within collinear-factorization approach. The results are compared with recent RHIC data. The new precise data at small transverse momenta impose stringent constraints on UGDFs. Some UGDFs are inconsistent with the new data. The Kwieciński UGDFs give the best description of the data. In order to verify the mechanism suggested here we propose J/ψ -jet correlation measurement and an independent measurement of χc meson production in π + π − and/or K + K − decay channels. Finally, we address the issue of J/ψ spin alignment.