You can but there are a few things you should know first...
It is called split option training and is only for reservists or national guardsmen. You would attend basic between your junior and senior year, with AIT following your graduation from highschool. You must be at least 17 years old at the time of enlistment and have a parental waiver if you are younger than 18. Also, it can be quite difficult to go active duty from the guard or reserves. It's not impossible by any means, but to do it you have to have a command release, which is sometimes not as easy as it sounds.
On a personal note, I don't recommend it, I did it and I almost regret it, partly because I was unable to go directly to active duty after AIT like I thought I could. The worst part about it though is it kinda messes with your soldier mentality. You start off as DEP (delayed entry program) soldier most of the time and you get used to your reserve unit. Then you hit basic which is nothing like your unit (or at least not mine) At basic you learn to be a soldier, they are on you, you have to stand at parade rest, snap to attention, and a rank or recognition of position is required after every answer. Then you go home. You're a senior in highschool and you forget all about basic and have fun for a change, except for the one weekend a month you are going to drill with your unit. Right after graduation you head back to that training environment. And for some it's a shocker. I was ok, but I didn't do PT on my own, or keep up with stuff like I should, and yes, I know that was my fault.
So if you do it, just be prepared to keep it going when you are in between training, it's not a vacation, it's just a little break to better yourself before gettin back to training....
I know it's long... sorry....
_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
Advice... Go upstairs, grab your big girl panties, and put them on....