The short answer is: yes, you absolutely can draw and animate in Java.
If you don't know anything about Java, you're going to want to go through the basic tutorials:
The Java™ Tutorials
Work through them to understand the basic concepts, and then move on to Swing to get a GUI up and running:
Trail: Creating a GUI With JFC/Swing (The Java™ Tutorials)
From there, move on to custom painting to draw whatever you want:
Lesson: Performing Custom Painting (The Java™ Tutorials > Creating a GUI With JFC/Swing)
Then use a Swing Timer to create an animation.
Alternatively, you could look into using Processing, which is a language built on top of Java specifically designed to make art and animation easier:
Processing.org
I've even written a series of tutorials for Processing that take you from not knowing anything to animating some basic scenes:
Static Void Games - Tutorials
I'd recommend working through those tutorials and looking at the examples that come with Processing.