Ride capacity is a calculation of the number of guests that can cycle through an attraction in an hour, so things like, how long the ride is, how many people can fit in a ride vehicle, how long it takes them to get on and off the ride, and how many vehicles operate at one time, are all factors.
Park capacity has even more variables because it not only factors in rice capacity, but also restaurant capacity, store capacity, and even the capacity of the park's walkways.
Generally, adding a new attraction where there wasn't one before adds to capacity because you have people on the ride and in line (and therefore not on paths, shopping, dining, or on other rides) that you didn't have before. A new ride using an existing system, like Frozen, wouldn't change the park's capacity because the ride capacity hasn't changed. A new ride with a new system could change the capacity for better or worse depending on the new ride system's capacity versus what it is replacing. Test Track and Mission: SPACE both lowered Epcot's capacity because World of Motion and Horizons were higher capacity rides.
Fastpasses also reduced the parks' capacity because now you have all those people not waiting in lines.