Hi Shishir,
For the Above requirement, You need to create like the below image shown
The Java class representation you mentioned is 1-1
The domain model Dhinesh mentioned is 1-*.
I dont see much difference other than this. But, always try to look at it from Domain model perspective, rather than Java class perspective.
you can use a helper entity if you want to see stored amounts of the pencil for specific stores one pencil (1-*)can be stored many amount (helper entity) related to the (*-1)specific store