Yes it looks like piles only. First you can try conservative management with medication. Even though if it is not resolving then you can go for surgery. Do you have any other skin issues at perianal region?
Next Steps
it needs to be clinically examined. so consult a general surgeon near you.
Health Tips
drink plenty of water and take high fibre diet. As long as you don't have constipation or passage of hard stools, the swelling will decrease.