Yes, those are geocaches! (One is open, one is closed.)
This is a typical "nano" container, and this type is usually magnetic, which is good, because it narrows down the places it can be hidden. If we are out hunting a nano geocache, we usually look for things that are metal, and search in those places. Inside is a tiny, tiny piece of scrolled up paper where you can just about barely write your name and the date. Obviously you have to bring your own pen or pencil when hunting one of these down.
This type of geocache is good for an "urban hide" because it can be "hidden" on a signpost, a metal bench, etc. in the middle of a busy sidewalk, for example. (I found one once that was on a leg of a post office mailbox which was clever, but in this day and age of fears of terrorism, and tampering with the mail and such, I felt very suspicious searching around it. Not a very good spot for a hide, in my opinion.)
But sometimes they sure can be tough little buggers to find! Some people "pooh pooh" the nano and micro geocaches because they feel geocaching is only fun if it means a hike in the woods, but we like all types of treasure hunts. :-)