We propose an agile sensing algorithm to optimally select the transmission waveform of a multiple-input, multiple-output (MIMO) radar system in order to improve target localization. Specifically, we first derive the Cramèr-Rao lower bound (CRLB) for the joint estimation of the antenna reflection coefficients and the range and direction-of-arrival of a stationary target using MIMO radar with colocated antennas. The resulting CRLB, that is a function of the transmitted waveform, is then compared to the estimation performance of a maximum-likelihood estimator. We configure waveform parameters to minimize the trace of the predicted error covariance by assuming that the covariance of the observation noise is approximated by the CRLB for high signal-to-noise ratios. In particular, we optimally select the duration and phase function parameters of generalized frequency-modulated chirps to minimize the estimation mean-squared error under constraints of fixed transmission energy and constant time-bandwidth product.