Grandmother´s house
Yesterday i went to visit my grandmother. She
baked me a lemon pie and gave a bag of cookies
to my family and I... but I ate
the whole bag
(of cookies) on the bus ride to my house.
"baked" is a term used for pies. However I suppose cooked also works, but it sounds a little funny. ;)
with the verb "to bake/to cook", you bake/cook something for people, not to people. but in this context, you don't need either because you can just say "baked me a lemon pie" because the "for" is implied.
Also, you used "me" several times in the same sentence and it's redundant to use it, so I took it out and changed it to "my family and I".
As for the word "the" in "the whole", since you mentioned the bag earlier, and are referring to it again, you have to clarify that it's the same bag by saying "the" whole bag.
The reason I put "of cookies" in parenthesis is because you can say "of cookies", but just like the word "me" in the first sentence, it is redundant and you don't need to say "of cookies" again. but it does work either way.
I changed "in the bus" to "on the bus ride" in the last sentence because that's the most common way of saying it, especially if you say "to my house".
great job! especially with the verb conjugation and use of different sentence structure! It looks like you got a little creative with your word choice and order, which is a great idea to learn a new language. even though there were a few mistakes, I can easily tell what you are trying to say, which is awesome! Keep up the good work!