Each component of your system should be utilized as it was designed to make it the "best". Things work better when they work according to their design. This, strictly, is my answer to your question.
The Relational Database
The purpose of a relational database is first to govern the integrity of your information and second to provide a storage and retrieval system. The RDMS governs your truth which then determines the way it should be stored and retrieved.
Since it is difficult, but not impossible, for us to imagine the uniqueness of digital discussion walls and of questions and replies we will typical use surrogate keys (i.e. auto generated numbers) for those entities' primary keys. This means the decision to add the Course ID to Questions, Replies, or BadgeAssignments will violate the principals relational design. You may say "no biggie" in this instance, but it is a violation nonetheless and will have consequences as long as it persists (pun intended).
If we used natural keys for Courses, Walls, Questions, Replies, and BadgeAssignments then our Primary Keys for each of those tables would be composites from those tables. We would then, for example, have the Primary Key of Courses within the Composite Primary Key of Replies without violating any principal of redundancy or normalization and your life would be "easier".
That said, what is so hard about this query?
SELECT
D.CourseId, D.CourseName
,A.ReplyId, A.ReplyName
FROM
Replies A
JOIN Questions B On A.QuestionId = B.QuestionId
JOIN Walls C ON B.WallId = C.WallId
JOIN Courses D ON C.CourseId = D.CourseId
Entity Framework
Entity Framework (EF) can be configured to match your design whether we put CourseId in Replies or whether we rely on the joins. But, we can usually do better than EF when it comes to SQL performance.
One option would be a to craft a SQL query (starting with the one above) that has the highest amount of optimization according to your need, and turn it into a View. Then, map a C# class to the View (instead of the tables) and the interactions are simplified. We would be letting EF exceed in providing low hassle data access and SQL succeed at retrieving data.
Here is the difference in C# Linq...
var replies = context.Replies
.Where(x => x.Questions.Walls.CourseId == 1)
.Select(x => new ReplyView
{
CourseId = x.Questions.Walls.Courses.CourseId,
CourseName = x.Questions.Walls.Courses.CourseName,
ReplyId = x.ReplyId,
ReplyName = x.ReplyName
}).ToList();
versus
var replies = context.RepliesView.Where(x => x.CourseId == 1).ToList();