An effective and interesting piece of writing uses a variety of sentence types for effect.
This sentence contains one main idea (or clause) which makes sense on its own and has one main verb.
Rosie kicked the ball.
A compound sentence usually joins two simple sentences (or two main clauses) using a conjunction or linking word
Rosie kicked the ball but Sophia ran away.
It is important to remember that the idea or clause either side of the conjunction should be able to make sense on its own.
This type of sentence has one main idea (or clause) and at least one extra idea (or subordinate clause) to give more information about the main point.
Rosie, who loved to play outside, kicked the ball
While the sun shone, Rosie kicked the ball.
In this case, the subordinate clause has to rely on the main clause for the sentence to make sense. It cannot exist on its own.