Just got an email from an elementary school student asking how to write a book. I started her off with these two suggestions, which apply to writers of all ages.
1. Read a lot of stories that are similar to the kind of book you want to write. A LOT. Like, sign out a great big pile of books from the library and read them all. Think about which ones you like best, and why. When we read like writers in that way, we learn what makes a good book.
2. Carry around a notebook. That way, when you have an idea, you can jot it down right away and it won't get lost in your busy brain.