The self-consistent Monte Carlo technique has been used to solve coupled nonlinear kinetic equations for electrons and optical phonons confined in a GaAs quantum well. We have studied the influence of nonequilibrium phonons on quasi-two-dimensional electron transport for a lattice temperature of 30 K and for a wide range of applied electric fields. A substantial difference in generation and decay times as well as the confinement inside the GaAs/AlAs heterostructure-bounded active region lead to a significant growth of nonequilibrium optical-phonon population generated by a heated electron gas. We have found that when the phonon generation (as well as phonon reabsorption by the quasi-two-dimensional carriers) becomes significant, there are substantial effects on transport in the quantum well. We show that for low electron concentrations, the hot optical-phonon distribution reflects the main features of the carrier distribution; indeed, it preserves an average quasi-momentum in the forward (opposite to electric field) direction. However, hot-phonon feedback to the electron system is found to be not essential in this case. For high electron concentrations, enhanced nonequilibrium optical-phonon reabsorption results in phonon distribution which spreads significantly in the quasi-momentum space and essentially loses the characteristic of the forward-peaked anisotropy. The interactions with the confined electron subsystem typically result in an isotropic phonon distribution. In this case, nonequilibrium optical phonons lead to an increase in the mean electron energy and a reduction in the carrier drift velocity.