Most people go through an "adjustment period" with their new mattress. This is completely normal and to be expected.
It is likely that your old mattress lost its support capabilities and your body got used to conforming to a non-supportive posture while sleeping. Just like new shoes can cause discomfort at first, your body needs to adjust to the "corrective action" of the new support system.
This adjustment period may last a few days or up to a month depending on the individual. 99% of the time, your initial discomfort will subside and you will be sleeping wonderfully in no time at all.