Doing time in juvenile detention lowers high school graduation rates and raises adult incarceration rates, economists find.