The ultraluminous infrared Seyfert 1 galaxy Mrk 231 has been spectrally imaged in the K band with the new three-dimensional MPE integral held spectrometer. The combined images of the H-2 emission lines show, for the first time in an ultraluminous infrared galaxy, the presence of an extended circumnuclear structure of hot molecular gas. The H-2 emitting region has a size of similar to 2.4 kpc and a hot molecular gas mass M(H2)(hot) similar to 2 x 10(4) M circle dot. The H-2 emission-line ratios indicate that the gas is most likely thermally excited. If as in NGC 7469 star formation is associated with the H-2 emission, the starburst would have a far-IR luminosity L(FIR) similar to 1 x 10(12) L circle dot. This value represents an upper limit, since a fraction of the hot molecular gas may be excited by the radiation field emerging from the nucleus. The K-band three-dimensional data cube also shows for the first time the presence of extended narrow Pa alpha emission blueshifted by similar to 1400 km s(-1) with respect to the systemic velocity, and located similar to 0.6 kpc northwest of the nucleus. The detection of CO absorption bands with a spatial distribution peaking on the K-band continuum provides evidence for a central stellar concentration. The low CO spectroscopic index indicates, however, dilution by hot dust emission or by a nonthermal active galactic nucleus. The Pa alpha/H alpha ratio confirms previous extinction measurements based on Balmer line ratios, i.e., visual extinction of A(V) similar to 2.0-6.6 mag. The quasar-type nucleus of Mrk 231 should then be transparent at 2 mu m and also in hard X-rays. A weak nuclear He I lambda 2.058 mu m (He I/Pa alpha = 0.032) is detected, and no detection of [Si VI] lambda 1.962 mu m is made, placing an upper limit of 4 x 10(-18) Wm(-2) for the coronal gas emission. The ionizing source could either be a far-UV and X-ray quiet quasar or else a nuclear starburst with an upper mass limit greater than or equal to 60 M circle dot.