An officer performing their duty is well within their rights to touch your car. The officer touching the back of the car is one aspect of them doing their job. However, the officer cannot search your vehicle without probable cause and your consent. Just touching the car and performing a search you did not consent two are two different things.